win64: add tiny unwind data for setjmp/longjmp

This enables native unwind semantics with longjmp on
win64 by putting an entry into the .pdata section for
each compiled fuction.

Also, the function now use a fixed stack and store arguments
into X(%rsp) rather than using push.
This commit is contained in:
grischka
2009-12-19 22:40:28 +01:00
parent 88a3ccab9f
commit 50b040ef83
7 changed files with 322 additions and 110 deletions

View File

@ -78,6 +78,13 @@ int tcc_run(TCCState *s1, int argc, char **argv)
return ret;
}
#endif
#ifdef TCC_TARGET_PE
{
unsigned char *p = tcc_get_symbol(s1, "tinyc_no_getbp");
if (p) *p = 0;
}
#endif
return (*prog_main)(argc, argv);
}