Home ]

 

Invalid Page Faults

Exception Errors

This information taken from Microsoft Knowledge Base. It's here more for my convenience than anything else, however please feel free to use it. Microsoft owns copyright on this information.

Does your computer stop responding (hang) or generate an Invalid Page Fault?

How to troubleshoot a hang or IPF.

What is an exception error?

An exception error signifies that something unexpected has happened within the Windows environment, typically an improper memory access. For example, a program or a Windows component might read or write to a memory location that has not been allocated to it (memory that it does not "own"), potentially overwriting and corrupting other program code in that area of memory. Fatal exception errors are typically of the form:

A fatal exception XY has occurred at xxxx:xxxxxxxx

A program returns a fatal exception errors when any of the following occur:

The program attempts to process an illegal instruction.
The program attempts to access invalid data or code.
The privilege level of an operation is invalid.

When any of these occur, the central processing unit (CPU) returns an exception to the operating system, which handles it as a fatal exception error. In many cases the exception is non-recoverable and the system must either be restarted or shut down, depending on the severity of the error.

In this example of a fatal exception error,

A fatal exception XY has occurred at xxxx:xxxxxxxx

the XY represents the actual processor exception from 00 to 0F. The xxxx:xxxxxxxx represents the enhanced instruction pointer to the code segment and the 8-bit address is the actual address in memory where the exception occurred.

Common Windows IPFs

When working with Microsoft Windows 9x, the most common error message you will get if the program hangs (stops responding) is an "Invalid Page Fault" or an IPF. The error message will be similar to the following:

This program has performed an illegal operation and will be shut down. If the problem persists, contact the program vendor.

If you click Details, you will receive the following error message:

"Program name" caused an invalid page fault in module module name at address

After you click OK, the program is shut down.

For more in-depth information about exception errors, please see the following articles in the Microsoft Knowledge Base:

ARTICLE-ID: Q150314
TITLE: What Are Windows 95 Fatal Exception Errors


Getting Clues from the Error Message

If you can gather clues about the component that is causing the IPF, you may be able to better target the specific cause of the problem. The first clue as to the cause of an IPF is in the IPF error message that is displayed. The error message will be similar to the following:

This program has performed an illegal operation and will be shut down. If the problem persists, contact the program vendor.

If you click Details, you will receive the following error message:

"Program name" caused an invalid page fault in module module name at address

After you click OK, the program is shut down.

Note the module name that is listed. If the module name is Winword.exe, then you must continue searching for the cause. Sometimes, however, the module name is a printer driver file, a video driver file, or some other non-Word component. If the module name is something that sounds familiar to you, such as a printer driver or a video driver, you can target your solution in those areas.

If the module name does not sound familiar or if you are unsure of which component it is a part of, you can search the Microsoft Support Site for more information.

Sometimes, removing and reinstalling the file mentioned in the IPF corrects the problem. If this does not correct the problem, or if you aren't sure how to remove and reinstall the file, continue troubleshooting

MORE INFORMATION

The following are the processor exceptions and their definitions:

00: Divide Fault

The processor returns this exception when it encounters a divide fault. A divide fault occurs if division by zero is attempted or if the result of the operation does not fit in the destination operand.

02: NMI interrupt

Interrupt 2 is reserved for the hardware Non-Maskable-Interrupt condition. No exceptions trap through interrupt 2.

04: Overflow trap

The overflow trap occurs after an INTO instruction has executed and the 0F bit is set to 1.

05: Bounds Check Fault

The BOUND instruction compares the array index with an upper and lower bound. If the index is out of range, then the processor traps to interrupt 05.

06: Invalid Opcode fault

This error is returned if any one of the following conditions are true:

   - The processor tries to decode a bit pattern that does not correspond
     to any legal computer instruction

   - The processor attempts to execute an instruction that contains invalid
     operands

   - The processor attempts to execute a protected-mode instruction while
     running in virtual 8086 mode.

   - The processor tries to execute a LOCK prefix with an instruction that
     cannot be locked.

07: Coprocessor not available fault

This error occurs if the computer does not have a math coprocessor and the EM bit of register CR0 is set indicating that Numeric Data Processor emulation is being used. Each time a floating point operation is executed, an interrupt 07 occurs.

This error also occurs when a math coprocessor is used and a task switch is executed. Interrupt 07 tells the processor that the current state of the coprocessor needs to be saved so that it can be used by another task.

08: Double Fault

Processing an exception sometimes triggers a second exception. In the event that this occurs, the processor will issue a interrupt 08 for a double fault.

09: Coprocessor Segment Overrun

This error occurs when a floating point instruction causes a memory access that runs beyond the end of the segment. If the starting address of the floating point operand is outside the segment, then a General Protection Fault occurs (interrupt 0D).

10 (0Ah): Invalid Task State Segment Fault

Because the Task State Segment contains a number of descriptors, any number of conditions may cause exception 0A. Typically, the processor can gather enough information from the Task State Segment to issue another fault pointing to the actual problem. See "Microsoft's Programming the 80386/80486 Guide" for more information.

11 (0Bh): Not Present Fault

The Not present interrupt allows the operating system to implement virtual memory through the segmentation mechanism. When a segment is marked as "not present", the segment is swapped out to disk. The interrupt 0B fault is triggered when an application needs access to the segment.

12 (0Ch): Stack Fault

A Stack Fault occurs with error code 0 if an instruction refers to memory beyond the limit of the stack segment. If the operating system supports expand-down segments, increasing the size of the stack should alleviate the problem. Loading the Stack Segment with invalid descriptors will result in a general protection fault.

13 (0Dh): General Protection Fault

Any condition which is not covered by any of the other processor exceptions will result in a general protection fault. The exception indicates that this program has been corrupted in memory usually resulting in immediate termination of the application.

14 (0Eh): Page Fault

The Page Fault interrupt allows the operating system to implement virtual memory on a demand-paged basis. An interrupt 14 usually is issued whenever an access to a page directory entry or page table with the present bit set to 0 (Not present) occurs. The operating system makes the page present (usually retrieves the page from virtual memory) and re-issues the faulting instruction, which then can access the segment. A page fault also occurs when a paging protection rule is violated (when the retrieve fails, or data retrieved is invalid, or the code that issued the fault broke the protection rule for the processor). In these cases the operating system takes over for the appropriate action.

16 (10h): Coprocessor error Fault

This interrupt occurs when an unmasked floating-point exception has been signaled a previous instruction. (Because the 80386 does not have access to the Floating Point Unit, it checks the ERROR\ pin to test for this condition). This is also triggered by a WAIT instruction if the Emulate Math Coprocessor bit at CR0 is set.

17 (11h): Alignment Check Fault

This interrupt is only used on the 80486 CPUs. An interrupt 17 is issued when code executing at ring privilege 3 attempts to access a word operand that is not on an even-address boundary, a double-word operand that is not divisible by four, or a long real or temp real whose address is not divisible by eight. Alignment checking is disabled when the CPU is first powered up and is only enabled in protected mode.

REFERENCES

For additional information, please see the following article(s) in the Microsoft Knowledge Base:

   ARTICLE-ID: Q138788
   TITLE     : Random Fatal Exception Errors While Running Windows 95

   ARTICLE-ID: Q136337
   TITLE     : Troubleshooting Windows 95 Startup Problems

   ARTICLE-ID: Q134503
   TITLE     : Parity Error Messages May Indicate Bad Memory

Microsoft's 80386/80486 Programming Guide, Second Edition

The Indispensable PC Hardware Book, Second edition

Microsoft Press Computer Dictionary, Second edition

 

Random Fatal Exception Errors While Running Windows 95/98

Last reviewed: June 23, 1998
Article ID: Q138788

The information in this article applies to:
Microsoft Windows 95
Microsoft Windows 98

SYMPTOMS

Windows reports random "Fatal Exception Error 0x:xxxxxxxx" error messages even though your previous version of Windows or Windows for Workgroups did not.

CAUSE

A common cause for these error messages is faulty physical memory (RAM) on the computer. The following are reasons why your previous version of Windows may appear to run smoothly while Windows may report random "Fatal Exception Error 0x:xxxxxxxx" error messages:

All operating systems use memory differently. In Windows 3.1, the "bad" memory may be used for holding rarely used data. In Windows, the "bad" memory is used for holding frequently run program information.
Windows 3.1 contains comparatively little 32-bit code. Windows uses much more 32-bit code. Furthermore, there are subtle differences between the way memory is accessed if it is being accessed for code or if it being accessed for data. Because Windows runs much more 32-bit code, these subtle errors show up more often.

In particular, all the 32-bit code in Windows 3.1 resides in one place: at the low-end of physical memory. If the first 4 megabytes (MB) of memory can handle 32-bit code, Windows 3.1 works without errors. This is true even if the topmost physical memory cannot run 32-bit code because Windows 3.1 does not run 32-bit code outside the first 4 MB of RAM.

Windows runs 32-bit code in all portions of memory. Therefore, when Windows runs 32-bit code in a section of RAM that cannot run 32-bit code well, you may receive "Fatal Exception Error 0x:xxxxxxxx" error messages.

Windows interacts with hardware differently than previous versions of Windows. This is due partly to Plug and Play and partly to new drivers that take advantage of the additional capabilities of interface adapters. These features may uncover anomalies in the hardware that never appeared in previous versions of Windows because earlier versions did not attempt to exploit these features.
Many new computers do not have memory chips that perform parity checking; therefore, you may have been encountering parity errors in Windows 3.1 without realizing it because the errors were in relatively harmless sections of memory. For example, in a Microsoft Word for Windows document, the word "the" is changed to "tie."

RESOLUTION

To resolve these errors, it is often necessary to replace the RAM and/or system board (motherboard). In some circumstances it may be possible to alter CMOS settings, such as Memory Wait States, to run Windows successfully. In other cases, disabling the motherboard L2 cache allows Windows to run. For information about how to edit CMOS settings, please view your computer documentation or contact your hardware manufacturer.

Note that you may want to restart Windows in Safe mode to see if the errors persist. If they do not, the problem may be a software or driver problem, in which case the information above may not apply. For information about how to troubleshoot Windows using Safe mode, see the following article in the Microsoft Knowledge Base:

   ARTICLE-ID: Q156126
   TITLE     : Troubleshooting Windows 95 Using Safe Mode

                              

MORE INFORMATION

Fatal exception errors are similar to EMM386 exception errors. For example, fatal exception error 0C is generally equivalent to EMM386 exception error 12 or a stack fault. For more information on exception errors, please see the following article in the Microsoft Knowledge Base:

   ARTICLE-ID: Q52195
   TITLE     : Exception Errors with EMM386.SYS / EMM386.EXE
                              

 

Electronic mail address
jaric@mindspring.com

Web and HomePage address
Tripod HomePage

Copyright © 1996-98 Richard Mask
Last revised: November 26, 2000.F