On 17 Feb 2008, at 20:43, Marc Santhoff wrote:

The code for FreeBSD in question looks like this:

case sig of
   SIGFPE :
         begin
           Case Info.si_code Of
               FPE_INTDIV : Res:=200;  {integer divide fault. Div0?}
               FPE_FLTOVF : Res:=205;  {Overflow trap}
               FPE_FLTUND : Res:=206;  {Stack over/underflow}
               FPE_FLTRES : Res:=216;  {Device not available}
FPE_FLTINV : Res:=216; {Invalid floating point operation}
              Else
               Res:=208; {coprocessor error}
               End;
            sysResetFPU;
         End;
   SIGILL,
   SIGBUS,
   SIGSEGV :
       res:=216;
 end;

What model of the i386 would be the best one for making a start?

You shouldn't need any cpu/fpu flags info. grep -r /usr/include for FPE_INTDIV, and see if there isn't also a constant for a floating point division by zero in the same file.


Jonas
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to