2 /* { dg-options "-fharden-control-flow-redundancy -fdump-tree-hardcfr --param hardcfr-max-blocks=9 --param hardcfr-max-inline-blocks=5 -ffat-lto-objects" } */
4 /* Check the instrumentation and the parameters. */
35 h (unsigned i
, int j
) /* { dg-warning "has more than 9 blocks, the requested maximum" } */
69 main (int argc
, char *argv
[])
71 if (f (1, 2) != 2 || g (2, 5) != 25 || h (4, 3) != 33
74 /* Call exit, instead of returning, to avoid an edge to the exit block and
75 thus implicitly disable hardening of main, when checking before noreturn
80 /* Inlined checking thus trap for f. */
81 /* { dg-final { scan-tree-dump-times "__builtin_trap" 1 "hardcfr" } } */
82 /* Out-of-line checking for g (param), and before both noreturn calls in main. */
83 /* { dg-final { scan-tree-dump-times "__hardcfr_check" 3 "hardcfr" } } */
84 /* No checking for h (too many blocks). */