I wrote a very simple c program:
#include
int main(){
int a=2;
int b=0;
printf(\"%d\\n\", a/b);
}
and run it wi
It might be that VM tests the divisor for 0 manually in emulated bytecode (for simplicity of implementation), but for performance will still switch to detecting the SIGFPE signal in JIT'd code. Try putting the division code in its own subroutine and call it in a loop thousands of times to ensure it gets compiled.