blob: cb8da01b7d5b105154b7fa9cceef5abc0b3718c6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
/* { dg-options "--coverage -fpath-coverage -g -O2" } */
/* { dg-do compile } */
/* { dg-require-effective-target sigsetjmp } */
#include <setjmp.h>
extern sigjmp_buf jmpbuf;
typedef void (*sfun) (void);
extern sfun getfn (int);
/* This distilled srunner setup/teardown functions in check-0.15.2. The
combination of setjmp, optimization, and debug statements causes a problem
if the gimple statement iterator is not positioned correctely before adding
instrumentation code. */
extern void
debug_after_labels (int *itr)
{
for (; *itr; ++itr)
{
sfun fn = getfn (*itr);
if (setjmp (jmpbuf) == 0)
fn ();
}
}
|