PR c/64856
[official-gcc.git] / gcc / testsuite / gcc.dg / tm / props-1.c
blob344e6df21a9be71523bd0c659bc696420d5704a4
1 /* { dg-do compile } */
2 /* { dg-options "-fgnu-tm -fdump-tree-tmedge -fdump-tree-tmlower" } */
4 int global;
6 void
7 foo(int local)
9 __transaction_atomic {
10 local++;
11 if (++global == 10)
12 __transaction_cancel;
16 /* { dg-final { scan-tree-dump-times " instrumentedCode" 1 "tmedge" } } */
17 /* { dg-final { scan-tree-dump-times "hasNoAbort" 0 "tmedge" } } */
18 /* { dg-final { scan-tree-dump-times "GTMA_HAVE_ABORT" 1 "tmlower" } } */
19 /* { dg-final { cleanup-tree-dump "tmedge" } } */
20 /* { dg-final { cleanup-tree-dump "tmlower" } } */