Commit f6bbf1ca by Jan Hubicka Committed by Jan Hubicka

alias-1_0.C: Use -O3.


	* g++.dg/lto/alias-1_0.C: Use -O3.
	* g++.dg/lto/alias-2_0.C: Use -O3.
	* g++.dg/lto/alias-3_0.C: Add loop to enable inlining with
	-fno-use-linker-plugin.
	* g++.dg/lto/alias-3_1.C: Remove dg-lto-do and dg-lto-options.

From-SVN: r273520
parent ee8c4549
2019-07-16 Jan Hubicka <jh@suse.cz>
* g++.dg/lto/alias-1_0.C: Use -O3.
* g++.dg/lto/alias-2_0.C: Use -O3.
* g++.dg/lto/alias-3_0.C: Add loop to enable inlining with
-fno-use-linker-plugin.
* g++.dg/lto/alias-3_1.C: Remove dg-lto-do and dg-lto-options.
2019-07-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> 2019-07-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* gcc.dg/tree-ssa/pr84512.c: Don't xfail scan-tree-dump on * gcc.dg/tree-ssa/pr84512.c: Don't xfail scan-tree-dump on
......
/* { dg-lto-do run } */ /* { dg-lto-do run } */
/* { dg-lto-options { { -O2 -flto } } } */ /* { dg-lto-options { { -O3 -flto } } } */
/* With LTO we consider all pointers to incomplete types to be possibly /* With LTO we consider all pointers to incomplete types to be possibly
aliasing. This makes *bptr to alias with aptr. aliasing. This makes *bptr to alias with aptr.
......
/* { dg-lto-do run } */ /* { dg-lto-do run } */
/* { dg-lto-options { { -O2 -flto } } } */ /* { dg-lto-options { { -O3 -flto } } } */
/* With LTO we consider all pointers to incomplete types to be possibly /* With LTO we consider all pointers to incomplete types to be possibly
aliasing. This makes *bptr to alias with aptr. aliasing. This makes *bptr to alias with aptr.
......
...@@ -14,13 +14,15 @@ __attribute__ ((used)) struct b b, *bptr=&b, *bptr2=&b; ...@@ -14,13 +14,15 @@ __attribute__ ((used)) struct b b, *bptr=&b, *bptr2=&b;
__attribute__ ((used)) int i,j; __attribute__ ((used)) int i,j;
extern "C" void inline_me_late (void); extern "C" void inline_me_late (void);
int n=1;
int int
main (void) main (void)
{ {
int jj=j; int jj=j;
bptr2->a[jj].bar = 0; bptr2->a[jj].bar = 0;
inline_me_late (); for (int i=0; i<n; i++)
inline_me_late ();
if (!__builtin_constant_p (bptr2->a[jj].bar == 0)) if (!__builtin_constant_p (bptr2->a[jj].bar == 0))
__builtin_abort (); __builtin_abort ();
return 0; return 0;
......
/* { dg-lto-do run } */
/* { dg-lto-options { { -O3 -flto -fno-early-inlining } } } */
struct a struct a
{ {
int foo,bar; int foo,bar;
......
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