On Thu, Jun 20, 2024 at 12:57 PM Maciej W. Rozycki <ma...@orcam.me.uk> wrote:
>
> On Thu, 20 Jun 2024, YunQiang Su wrote:
>
> > The DIV instructions of MIPS won't be trapped themself if the divisor
> > is zero.  The compiler will emit a conditional trap instruct for it.
> > So the signal will be SIGTRAP instead of SIGFPE.
>
>  It's an OS kernel bug if you get SIGTRAP for integer division by zero, so
> if a test case fails, it rightfully does.

MIPS doesn't trap on integer division by zero, instead it's a GCC bug that
we emit a conditional trapping instruction.  So I think the fix is fine and
accurate.

Richard.

>   Maciej

Reply via email to