summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tm/debug-1.c
blob: 01acfae4d03b309f26d826981e7989abe4ffe845 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/* { dg-do compile } */
/* { dg-options "-fgnu-tm -O0 -fdump-tree-tmmark-lineno" } */

/* Test that instrumented statements have correct location info.  */

int a,b, c, z;

testing(){
    c=9;
}

main() {
	b = 9898;
	__transaction_relaxed {
		z = c;
		a = 888;
		testing();
	}
	return 0;
}

/* { dg-final { scan-tree-dump-times ": 13:.*b = 9898" 1 "tmmark" } } */
/* { dg-final { scan-tree-dump-times ": 14:.*_ITM_beginTransaction" 1 "tmmark" } } */
/* { dg-final { scan-tree-dump-times ": 15:.*ITM_WU. \\(&z" 1 "tmmark" } } */
/* { dg-final { scan-tree-dump-times ": 16:.*ITM_WU. \\(&a" 1 "tmmark" } } */
/* { dg-final { cleanup-tree-dump "tmmark" } } */