Causes of General Protection Faults

ID: Q82710


The information in this article applies to:


SUMMARY

Intel 80286, 80386, and 80486 CPUs can detect when a program does something wrong. The most common problems are stack faults, invalid instructions, divide errors (divide by zero), and general protection faults. These generally indicate nonstandard code in an application.


MORE INFORMATION

The following faults can occur in a Windows application, in Windows itself, or in a Windows device driver (for example, a video display driver).

Stack Fault (Interrupt 12)

Reasons for a stack fault are:
Stack faults are always fatal to the current application in Windows.

Invalid Instruction (Interrupt 6)

The CPU detects most invalid instructions, and generates an Interrupt and is usually caused by executing data instead of code.

Divide Error (Interrupt 0)

This is caused when the destination register cannot hold the result of a divide operation. It could be divide by zero, or divide overflow.

General Protection Fault (Interrupt 13)

All protection violations that do not cause another exception cause a general protection exception. This includes, but is not limited to:

Additional query words: 3.10 gpfault 3.0a \* TestWin4


Keywords          : win31 win95 winmem win98 wfwg 
Version           : WINDOWS:3.1,3.11,98
Platform          : WINDOWS 
Issue type        : kbinfo 

Last Reviewed: January 13, 1999