Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /sml/trunk/runtime/mach-dep/unix-fault.c
ViewVC logotype

Diff of /sml/trunk/runtime/mach-dep/unix-fault.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3431, Sun Sep 13 17:10:57 2009 UTC revision 3432, Sun Sep 13 17:50:53 2009 UTC
# Line 70  Line 70 
70     /* Map the signal to the appropriate ML exception. */     /* Map the signal to the appropriate ML exception. */
71  #if defined(HOST_X86) && defined(OPSYS_DARWIN)  #if defined(HOST_X86) && defined(OPSYS_DARWIN)
72    /* NOTE: early versions of Mac OS X 10.4.x set the code to FPE_FLTDIV or    /* NOTE: early versions of Mac OS X 10.4.x set the code to FPE_FLTDIV or
73     * FPE_FLTOVF, but 10.4.7 sets it to 0, so we need this workaround.     * FPE_FLTOVF, but 10.4.7 sets it to 0, so we need this workaround.  With
74       * 10.6, the correct FPE_INTOVF and FPE_INTDIV codes are now used.
75     */     */
76      if ((signal == SIGFPE) && (code == 0)) {      if ((signal == SIGFPE) && (code == 0)) {
77          if (((Byte_t *)SIG_GetPC(scp))[-1] == INTO_OPCODE)          if (((Byte_t *)SIG_GetPC(scp))[-1] == INTO_OPCODE)
78              code = FPE_FLTOVF;              code = FPE_INTOVF;
79          else          else
80              code = FPE_FLTDIV;              code = FPE_INTDIV;
81      }      }
82  #endif  #endif
83      if (INT_OVFLW(signal, code)) {      if (INT_OVFLW(signal, code)) {

Legend:
Removed from v.3431  
changed lines
  Added in v.3432

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0