8 * This test checks whether processes/threads get execute permission
9 * on the stack if needed, in particular for multiple threads.
10 * It depends on the fact that gcc puts trampoline code for
11 * nested functions on the stack and requests execution permission
12 * for that address internally, at least on some architectures.
13 * (On the other architectures, the test is just insignificant.)
14 * Actually, it would be better if gcc wouldn't use stack trampolines,
15 * at all, but for now it allows for an easy portable check whether the
16 * kernel handles permissions correctly.
37 signal(SIGBUS
, buserr
);
39 pthread_create(&t1
, 0, mist
, 0);
40 pthread_create(&t2
, 0, mist
, 0);