Sync with upstream 4.9 branch
[official-gcc.git] / embedded-4_9-branch / gcc / testsuite / c-c++-common / asan / instrument-with-calls-2.c
blob1b361e6270d23e9f54c0f21a8ad2b8efd6e9cb8c
1 /* { dg-do assemble } */
2 /* { dg-options "-fno-sanitize=address -fsanitize=kernel-address --param asan-instrumentation-with-call-threshold=1 -save-temps" } */
4 int x;
6 void f(int *a, int *b) {
7 *a = 0;
8 asm volatile ("" ::: "memory");
9 x = *b;
12 /* { dg-final { scan-assembler "__asan_store4" } } */
13 /* { dg-final { scan-assembler-not "__asan_report_store4" } } */
14 /* { dg-final { scan-assembler "__asan_load4" } } */
15 /* { dg-final { scan-assembler-not "__asan_report_load4" } } */
16 /* { dg-final { cleanup-saved-temps } } */