same line for all architectures.
Promote the s390x exp file to be the golden one because it has the
correct result. Add exp-kfail files for those platforms where the testcases
fail (x86).
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12097
descriptor, not to the function's entry point. Hence to get
uniform behaviour on all supported targets - a jump to an
unmapped page - the following is needed. */
- unsigned long long int fake_fndescr[3];
- fake_fndescr[0] = (unsigned long long int)get_unmapped_page();
- fake_fndescr[1] = 0;
- fake_fndescr[2] = 0;
- return ((int(*)(void)) fake_fndescr) ();
+ unsigned long long int p[3];
+ p[0] = (unsigned long long int)get_unmapped_page();
+ p[1] = 0;
+ p[2] = 0;
#else
char* p = get_unmapped_page();
- return ((int(*)(void)) p) ();
#endif
+ return ((int(*)(void)) p) ();
}
Jump to the invalid address stated on the next line
...
+ by 0x........: main (badjump.c:17)
Address 0x........ is not stack'd, malloc'd or (recently) free'd
Process terminating with default action of signal 11 (SIGSEGV)
Access not within mapped region at address 0x........
...
+ by 0x........: main (badjump.c:17)
If you believe this happened as a result of a stack
overflow in your program's main thread (unlikely but
possible), you can try to increase the size of the
Jump to the invalid address stated on the next line
...
- by 0x........: main (badjump.c:17)
Address 0x........ is not stack'd, malloc'd or (recently) free'd
Process terminating with default action of signal 11 (SIGSEGV)
Access not within mapped region at address 0x........
...
- by 0x........: main (badjump.c:17)
If you believe this happened as a result of a stack
overflow in your program's main thread (unlikely but
possible), you can try to increase the size of the
if (__builtin_setjmp(myjmpbuf) == 0) {
// Jump to zero; will cause seg fault
#if defined(__powerpc64__)
- unsigned long int fake_fndescr[3];
- fake_fndescr[0] = 0;
- fake_fndescr[1] = 0;
- fake_fndescr[2] = 0;
- ((void(*)(void)) fake_fndescr) ();
+ unsigned long int fn[3];
+ fn[0] = 0;
+ fn[1] = 0;
+ fn[2] = 0;
#else
void (*fn)(void) = 0;
- fn();
#endif
+ ((void(*)(void)) fn) ();
fprintf(stderr, "Got here??\n");
} else {
fprintf(stderr, "Signal caught, as expected\n");
Jump to the invalid address stated on the next line
...
+ by 0x........: main (badjump2.c:46)
Address 0x........ is not stack'd, malloc'd or (recently) free'd
Signal caught, as expected
Jump to the invalid address stated on the next line
...
- by 0x........: main (badjump2.c:46)
Address 0x........ is not stack'd, malloc'd or (recently) free'd
Signal caught, as expected