When you get an invalid instruction the kernel traps it and delivers it
as a signal to the process (which by default dies with 'illegal instruction'
and probably (core dumped). If you trap that signal SIGILL with your own
handler you can write code of the form
if(instruction_is_valid_mmx(x))
emulate_it();
else
{
signal(SIGILL, SIG_DFL); /* Die die.. */
raise(SIGILL);
}
> than non-mmx users, the have other compilers (pcg pgcc, egcs, whatever),
> or at least other switches (-mamdk6 -m....). why not simply add mmx to the
> compiler, skip the emulator, make it a recompilation option, widen the use
> of autoconf / automake, and here we go?
>
> and -- NEVER distribute mmx binaries in publix without providing non-mmx
> ones.
That bit is the issue. In the MMX case MMX is weird and wacky enough its
unlikely to get generally used except in stuff like graphics libraries
Alan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu