1 /* { dg-do compile { target R_flag_in_section } } */
2 /* { dg-options "-Wall -O2" } */
3 
4 static int xyzzy __attribute__((__used__, __retain__)) = 1;
5 
foo()6 void foo()
7 {
8   int x __attribute__((__retain__)); /* { dg-warning "attribute ignored|unused variable" } */
9 }
10 
11 /* { dg-final { scan-assembler "xyzzy" } } */
12 /* { dg-final { scan-assembler "\.data.*,\"awR\"" { target R_flag_in_section } } } */
13