c++: constantness of call to function pointer [PR111703]
[official-gcc.git] / gcc / testsuite / g++.dg / torture / harden-cfr-throw-always.C
blob4d303e769ef72d95e686c65d5471212067c3817c
1 /* { dg-do compile } */
2 /* { dg-options "-fharden-control-flow-redundancy -fno-hardcfr-check-returning-calls -fhardcfr-check-noreturn-calls=always -fdump-tree-hardcfr -ffat-lto-objects" } */
4 /* Check that we insert cleanups for checking around the bodies of
5    maybe-throwing functions, and also checking before noreturn
6    calls.  */
8 #include "harden-cfr-throw.C"
10 /* { dg-final { scan-tree-dump-times "hardcfr_check" 14 "hardcfr" } } */
11 /* { dg-final { scan-tree-dump-times "builtin_trap" 1 "hardcfr" } } */
12 /* h, h2, h2b, and h4.  */
13 /* { dg-final { scan-tree-dump-times "Bypassing" 4 "hardcfr" } } */