[PATCH]: testsuite fixes for loadpre5.c/loadpre8.c with -fpic/-fPIC
Hans-Peter Nilsson
hp@bitrange.com
Sun Jan 13 00:19:00 GMT 2008
On Thu, 10 Jan 2008, Kaveh R. GHAZI wrote:
> diff -rup orig/egcc-SVN20080110/gcc/testsuite/gcc.dg/tree-ssa/loadpre8.c egcc-SVN20080110/gcc/testsuite/gcc.dg/tree-ssa/loadpre8.c
> --- orig/egcc-SVN20080110/gcc/testsuite/gcc.dg/tree-ssa/loadpre8.c 2008-01-03 23:34:32.000000000 +0100
> +++ egcc-SVN20080110/gcc/testsuite/gcc.dg/tree-ssa/loadpre8.c 2008-01-11 05:41:17.000000000 +0100
> @@ -24,7 +24,7 @@ typedef struct VEC_edge_base
> {
> }
> VEC_edge_base;
> -__attribute__ ((noinline)) edge
> +__attribute__ ((noinline)) static edge
> VEC_edge_base_index (const VEC_edge_base * vec_, unsigned ix_)
> {
> }
> @@ -56,7 +56,7 @@ ei_start_1 (VEC_edge_gc ** ev)
> i.container = ev;
> return i;
> }
> -__attribute__ ((noinline)) ei_next (edge_iterator * i)
> +__attribute__ ((noinline)) static ei_next (edge_iterator * i)
> {
> }
> static __inline__ edge
> @@ -75,7 +75,7 @@ static __inline__ tree
> get_def_from_ptr (def_operand_p def)
> {
> }
> -__attribute__ ((noinline)) tree
> +__attribute__ ((noinline)) static tree
> phi_nodes (basic_block bb)
> {
> }
>
Looks like all those functions are pure/const and the calls
likely removed (no that's *not* inlining. ;) Even more so, now
that they're static. A perfect point of the caveat presented in
<http://gcc.gnu.org/ml/gcc/2008-01/msg00165.html>.
(Stick an asm ("") in there or add -fno-ipa-pure-const; you
can't make a static fn weak.)
brgds, H-P
More information about the Gcc-patches
mailing list