blob: 613c44c6f8255eedf7f07ad80a77566e2b874ffe [file] [log] [blame]
/* { dg-do compile } */
/* { dg-options "-O2 -mno-indirect-branch-register -mfunction-return=keep -mindirect-branch=thunk-extern -mharden-sls=return" } */
/* { dg-additional-options "-fno-pic" { target { ! *-*-darwin* } } } */
typedef void (*dispatch_t)(long offset);
dispatch_t dispatch;
int
male_indirect_jump (long offset)
{
dispatch(offset);
return 0;
}
/* { dg-final { scan-assembler-times "ret" 1 } } */
/* { dg-final { scan-assembler-times "int3" 1 } } */