Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is a single step exception?

Tags:

asp.net

What is a single step exception? In the context of a stack trace and a break point?

Cheers, J

like image 907
JHarley1 Avatar asked Dec 27 '10 14:12

JHarley1


People also ask

What is single stepping debugging?

Single-stepping is one of the most powerful features of a debugger, as it allows a reverse engineer to execute a single instruction at a time before returning control to the debugger.

What is single step execution?

A single step is when a program is executed one step at a time. Usually, to locate a flaw or error that is causing the program not to operate properly. Debugging, Programming terms.

What happens if a kernel mode driver generates an unhandled exception?

Exceptions that occur in kernel-mode code are more serious than user-mode exceptions. If kernel-mode exceptions are not handled, a bug check is issued and the system stops.


1 Answers

This exception usually is a trap (a kind of exception, which itself is a kind of interrupt) that is raised by the CPU.

A common debugging scenario is:

  1. Breakpoint is hit
  2. User asks the debugger to "single step" exactly one line of code
  3. line of code is executed
  4. CPU raises single step execution (exception code 1)
  5. Debugger catches single step exception (and usually nicely handles this by highlighting the next line and updating variable watches)

However, this exception can also be raised in other cases. You can refer to http://support.microsoft.com/kb/117389 as a starting point.

like image 64
Ramsey Avatar answered Sep 30 '22 03:09

Ramsey