delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/08/16/23:16:30

Date: Mon, 17 Aug 1998 02:50:21 +0000 ( )
From: "Gurunandan R. Bhat" <grbhat AT unigoa DOT ernet DOT in>
To: djgpp AT delorie DOT com
Subject: Stack of a exception handler
Message-Id: <Pine.LNX.3.91.980817024348.4306A-100000@aditya.unigoa.ernet.in>
Mime-Version: 1.0

Greetings,

	The stack of an exception handler (src/libc/go32/exceptn.s) is 
given as:

      [   *   |   SS  ]  
      [      ESP      ]
      [    EFLAGS     ]
      [   *   |   CS  ] 
      [      EIP      ]
      [   ERR CODE    ]
      [   *   |RET CS*]  
      [   RET EIP*    ]   
      [  EXCEPTION #  ]  

While the first six dwords (starting from SS) are pushed by the CPU, and
EXCEPTION # is pushed by the handler, who pushes RET CS* and RET EIP*. 

If CS:EIP is the location in the application code segment where the
exception occurs, what location does RET-CS:RET-EIP represent? 

Many thanks.
Gurunandan
 

- Raw text -


  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019