mirror of
https://github.com/rdolbeau/VexRiscvBPluginGenerator.git
synced 2025-04-18 18:44:42 -04:00
16 lines
212 B
C
16 lines
212 B
C
|
|
#include <signal.h>
|
|
#include <setjmp.h>
|
|
|
|
jmp_buf jb;
|
|
|
|
static void sighandler(int x)
|
|
{
|
|
longjmp(jb, 1);
|
|
}
|
|
|
|
static void (*oldsig)(int);
|
|
|
|
void installillhandler(void) {
|
|
oldsig = signal(SIGILL, sighandler);
|
|
}
|