PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / indirect-thunk-bnd-2.c
blob856751ac2241aa57306aac9f8897b0d5046a1975
1 /* { dg-do compile { target { ! x32 } } } */
2 /* { dg-options "-O2 -mno-indirect-branch-register -mfunction-return=keep -mindirect-branch=thunk -fcheck-pointer-bounds -mmpx -fno-pic" } */
4 void (*dispatch) (char *);
5 char buf[10];
7 int
8 foo (void)
10 dispatch (buf);
11 return 0;
14 /* { dg-final { scan-assembler "mov(?:l|q)\[ \t\]*_?dispatch" { target *-*-linux* } } } */
15 /* { dg-final { scan-assembler "bnd call\[ \t\]*__x86_indirect_thunk_bnd_(r|e)ax" } } */
16 /* { dg-final { scan-assembler "bnd call\[ \t\]*\.LIND" } } */
17 /* { dg-final { scan-assembler "bnd ret" } } */
18 /* { dg-final { scan-assembler {\tpause} } } */
19 /* { dg-final { scan-assembler {\tlfence} } } */