summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/hle-sub-rel-1.c
blob: 3a8c04e5d0af33dcedb31a1c440a26662c57f8b6 (plain)
1
2
3
4
5
6
7
8
9
/* { dg-do compile } */
/* { dg-options "-mhle" } */
/* { dg-final { scan-assembler "lock;?\[ \n\t\]+\(xrelease\|\.byte\[ \t\]+0xf3\)\[ \t\n\]+sub" } } */

void
hle_sub (int *p, int v)
{
  __atomic_fetch_sub (p, v, __ATOMIC_RELEASE | __ATOMIC_HLE_RELEASE);
}