* gcc.c-torture/execute/alias-4.c: New testcase.
From-SVN: r232411
This commit is contained in:
parent
824ca15e29
commit
0f6176e67c
@ -1,3 +1,7 @@
|
||||
2016-01-15 Jan Hubicka <hubicka@ucw.cz>
|
||||
|
||||
* gcc.c-torture/execute/alias-4.c: New testcase.
|
||||
|
||||
2016-01-15 Jan Hubicka <hubicka@ucw.cz>
|
||||
|
||||
PR ipa/68148
|
||||
|
19
gcc/testsuite/gcc.c-torture/execute/alias-4.c
Normal file
19
gcc/testsuite/gcc.c-torture/execute/alias-4.c
Normal file
@ -0,0 +1,19 @@
|
||||
/* { dg-require-alias "" } */
|
||||
int a = 1;
|
||||
extern int b __attribute__ ((alias ("a")));
|
||||
int c = 1;
|
||||
extern int d __attribute__ ((alias ("c")));
|
||||
main (int argc)
|
||||
{
|
||||
int *p;
|
||||
int *q;
|
||||
if (argc)
|
||||
p = &a, q = &b;
|
||||
else
|
||||
p = &c, q = &d;
|
||||
*p = 1;
|
||||
*q = 2;
|
||||
if (*p == 1)
|
||||
__builtin_abort ();
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user