gcc/testsuite/gcc.target/m68k/20090709-1.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* There should be 3 occurrences of .LC0 in the code: |
| 3 | one for the definition of "0", |
| 4 | one for use in test2(). |
| 5 | The occurrence in test1 is collapsed to an integer constant |
| 6 | FIXME: At the moment m68k GCC does not optimize test1() to nop |
| 7 | for some reason. */ |
| 8 | /* { dg-final { scan-assembler-times ".LC0" 2 } } */ |
| 9 | |
| 10 | void dummy(char *arg); |
| 11 | |
| 12 | void test1(void) |
| 13 | { |
| 14 | char tmp[2] = "0"; |
| 15 | } |
| 16 | |
| 17 | void test2(void) |
| 18 | { |
| 19 | dummy("0"); |
| 20 | } |