view gcc/testsuite/c-c++-common/tm/pr54893.c @ 152:2b5abeee2509

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents 1830386684a0
children
line wrap: on
line source

/* { dg-do compile } */
/* { dg-options "-fgnu-tm -fdump-ipa-tmipa" } */
/* { dg-additional-options "-Wno-volatile" { target c++ } } */

/* Test that volatiles are allowed inside relaxed transactions.  */

volatile int test_var = 0;

int main()
{
  __transaction_relaxed {
    test_var++;
  }
}

/* { dg-final { scan-ipa-dump "GTMA_DOES_GO_IRREVOCABLE" "tmipa" } } */