diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/alias-15.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/alias-15.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/alias-15.c b/gcc/testsuite/gcc.dg/alias-15.c new file mode 100644 index 00000000000..0a8e69b61ec --- /dev/null +++ b/gcc/testsuite/gcc.dg/alias-15.c @@ -0,0 +1,15 @@ +/* { dg-do compile } */ +/* { dg-additional-options "-O2 -fdump-ipa-cgraph" } */ + +/* RTL-level CSE shouldn't introduce LCO (for the string) into varpool */ +char *p; + +void foo () +{ + p = "abc\n"; + + while (*p != '\n') + p++; +} + +/* { dg-final { scan-ipa-dump-not "LC0" "cgraph" } } */ |