Commit 12cdc4fa by Jakub Jelinek Committed by Jakub Jelinek

decl.c (start_preparsed_function): Set DECL_DISREGARD_INLINE_LIMITS for GNU_INLINE_P functions.

	* decl.c (start_preparsed_function): Set
	DECL_DISREGARD_INLINE_LIMITS for GNU_INLINE_P functions.

	* gcc.dg/inline-24.c: New test.
	* g++.dg/opt/inline11.C: New test.

From-SVN: r127929
parent ca2ba153
2007-08-30 Jakub Jelinek <jakub@redhat.com>
* decl.c (start_preparsed_function): Set
DECL_DISREGARD_INLINE_LIMITS for GNU_INLINE_P functions.
PR target/33168
* config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Return
true if any of the compare_section_name calls returned true,
......
......@@ -10892,6 +10892,7 @@ start_preparsed_function (tree decl1, tree attrs, int flags)
DECL_EXTERNAL (decl1) = 1;
DECL_NOT_REALLY_EXTERN (decl1) = 0;
DECL_INTERFACE_KNOWN (decl1) = 1;
DECL_DISREGARD_INLINE_LIMITS (decl1) = 1;
}
if (DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P (decl1))
......
2007-08-30 Jakub Jelinek <jakub@redhat.com>
* gcc.dg/inline-24.c: New test.
* g++.dg/opt/inline11.C: New test.
2007-08-30 Richard Guenther <rguenther@suse.de>
* gcc.target/i386/vectorize5.c: New testcase.
/* Verify that gnu_inline inlines disregard inlining limits. */
/* { dg-do link } */
/* { dg-options "-O2" } */
extern int foo (int);
extern int baz (int);
extern inline __attribute__((gnu_inline))
int foo (int x)
{
int i;
if (!__builtin_constant_p (x))
{
#define B(n) baz (1##n) + baz (2##n) + baz (3##n) \
+ baz (4##n) + baz (5##n) + baz (6##n)
#define C(n) B(1##n) + B(2##n) + B(3##n) + B(4##n) + B(5##n) + B(6##n)
#define D(n) C(1##n) + C(2##n) + C(3##n) + C(4##n) + C(5##n) + C(6##n)
return D(0) + D(1) + D(2) + D(3) + D(4)
+ D(5) + D(6) + D(7) + D(8) + D(9);
}
return 0;
}
int
main (void)
{
return foo (0);
}
/* Verify that gnu_inline inlines disregard inlining limits. */
/* { dg-do link } */
/* { dg-options "-O2" } */
extern int foo (int);
extern int baz (int);
extern inline __attribute__((gnu_inline))
int foo (int x)
{
int i;
if (!__builtin_constant_p (x))
{
#define B(n) baz (1##n) + baz (2##n) + baz (3##n) \
+ baz (4##n) + baz (5##n) + baz (6##n)
#define C(n) B(1##n) + B(2##n) + B(3##n) + B(4##n) + B(5##n) + B(6##n)
#define D(n) C(1##n) + C(2##n) + C(3##n) + C(4##n) + C(5##n) + C(6##n)
return D(0) + D(1) + D(2) + D(3) + D(4)
+ D(5) + D(6) + D(7) + D(8) + D(9);
}
return 0;
}
int
main (void)
{
return foo (0);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment