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/src/runtime/mach-dep/unix-fault.c
ViewVC logotype

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

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

revision 692, Thu Jul 27 08:34:53 2000 UTC revision 693, Thu Jul 27 15:49:07 2000 UTC
# Line 58  Line 58 
58   */   */
59  PVT SigReturn_t FaultHandler (  PVT SigReturn_t FaultHandler (
60      int             signal,      int             signal,
61  #if defined(OPSYS_LINUX)  #if (defined(TARGET_X86) && defined(OPSYS_LINUX))
62      SigContext_t    sc)      SigContext_t    sc)
63  #elif defined(OPSYS_MKLINUX)  #elif (defined(TARGET_PPC) && defined(OPSYS_LINUX))
64      SigContext_t    *scp)      SigContext_t    *scp)
65  #else  #else
66      SigInfo_t       info,      SigInfo_t       info,
67      SigContext_t    *scp)      SigContext_t    *scp)
68  #endif  #endif
69  {  {
70  #if defined(OPSYS_LINUX)  #if (defined(TARGET_X86) && defined(OPSYS_LINUX))
71      SigContext_t    *scp = ≻      SigContext_t    *scp = ≻
72  #endif  #endif
73      ml_state_t      *msp = SELF_VPROC->vp_state;      ml_state_t      *msp = SELF_VPROC->vp_state;
# Line 83  Line 83 
83          Die ("bogus fault not in ML: (%d, %#x)\n", signal, SIG_GetCode(info, scp));          Die ("bogus fault not in ML: (%d, %#x)\n", signal, SIG_GetCode(info, scp));
84    
85     /* Map the signal to the appropriate ML exception. */     /* Map the signal to the appropriate ML exception. */
86      if (INT_DIVZERO(signal, code)) {      if (INT_OVFLW(signal, code)) {
87          msp->ml_faultExn = DivId;          msp->ml_faultExn = OverflowId;
88          msp->ml_faultPC = (Word_t)SIG_GetPC(scp);          msp->ml_faultPC = (Word_t)SIG_GetPC(scp);
89      }      }
90      else if (INT_OVFLW(signal, code)) {      else if (INT_DIVZERO(signal, code)) {
91          msp->ml_faultExn = OverflowId;          msp->ml_faultExn = DivId;
92          msp->ml_faultPC = (Word_t)SIG_GetPC(scp);          msp->ml_faultPC = (Word_t)SIG_GetPC(scp);
93      }      }
94      else      else
# Line 115  Line 115 
115   */   */
116  PVT SigReturn_t PanicTrace (  PVT SigReturn_t PanicTrace (
117      int             signal,      int             signal,
118  #if defined(OPSYS_LINUX)  #if (defined(TARGET_X86) && defined(OPSYS_LINUX))
119      SigContext_t    sc)      SigContext_t    sc)
120  #else  #else
121      SigInfo_t       info,      SigInfo_t       info,
122      SigContext_t    *scp)      SigContext_t    *scp)
123  #endif  #endif
124  {  {
125  #if defined(OPSYS_LINUX)  #if (defined(TARGET_X86) && defined(OPSYS_LINUX))
126      SigContext_t    *scp = ≻      SigContext_t    *scp = ≻
127  #endif  #endif
128    

Legend:
Removed from v.692  
changed lines
  Added in v.693

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