1 /* { dg-do compile } */
2 /* { dg-options "-fgnu-tm -fdump-ipa-tmipa" } */
3 
4 /* Test that irrevocability gets set for the obvious case.  */
5 
6 int global;
7 int george;
8 
9 extern crap() __attribute__((transaction_unsafe));
10 
foo()11 foo(){
12     __transaction_relaxed {
13 	global++;
14 	crap();
15 	george++;
16     }
17 }
18 
19 /* { dg-final { scan-ipa-dump-times "GTMA_MAY_ENTER_IRREVOCABLE" 1 "tmipa" } } */
20 /* { dg-final { cleanup-ipa-dump "tmipa" } } */
21