S
Sune Foldager
Greetings
We have a (rather large) project at work which consist of almost only managed
C# code, with a little interop-code. Recently, we encountered a strange error
(an AccessViolationException) occurring only in the following setup:
a) Windows Vista 64bit (32bit works fine)
b) Visual Studio 2008 (with or without Service Pack 1)
c) Only when building in release mode
d) Only when starting the program normally; When starting it with the Visual
Studio debugger, the error does not occur. If we attach to it while running
(with VS), the error does occur but VS never catches the produced exception.
The AccessViolationException is catched in our program. The stack trace (we
have pdb files even in release mode) shows one of our methods as originator,
but no line numbers. We think it may be caused in the JITting of that method,
based on the following dump from windbg:
(11bc.7ac): Access violation - code c0000005 (first chance)
First chance exceptions are reported before any exception handling.
This exception may be expected and handled.
mscorjit!LifetimesFindDefOutsideOfTryForOpTryEndPhi+0x14:
000007fe`f0d85fd4 4c8b4818 mov r9,qword ptr [rax+18h] ds:00000000`00000018=????????????????
0:031> g
(11bc.7ac): C++ EH exception - code e06d7363 (first chance)
(11bc.7ac): Access violation - code c0000005 (first chance)
First chance exceptions are reported before any exception handling.
This exception may be expected and handled.
KERNEL32!RaiseException+0x39:
00000000`7730649d 4881c4c8000000 add rsp,0C8h
Originating from mscorjit, it seems. Does anyone know what the cause of this
could be or how we could aid in debugging the problem further?
Sincerly,
Sune Foldager
Edlund A/S
We have a (rather large) project at work which consist of almost only managed
C# code, with a little interop-code. Recently, we encountered a strange error
(an AccessViolationException) occurring only in the following setup:
a) Windows Vista 64bit (32bit works fine)
b) Visual Studio 2008 (with or without Service Pack 1)
c) Only when building in release mode
d) Only when starting the program normally; When starting it with the Visual
Studio debugger, the error does not occur. If we attach to it while running
(with VS), the error does occur but VS never catches the produced exception.
The AccessViolationException is catched in our program. The stack trace (we
have pdb files even in release mode) shows one of our methods as originator,
but no line numbers. We think it may be caused in the JITting of that method,
based on the following dump from windbg:
(11bc.7ac): Access violation - code c0000005 (first chance)
First chance exceptions are reported before any exception handling.
This exception may be expected and handled.
mscorjit!LifetimesFindDefOutsideOfTryForOpTryEndPhi+0x14:
000007fe`f0d85fd4 4c8b4818 mov r9,qword ptr [rax+18h] ds:00000000`00000018=????????????????
0:031> g
(11bc.7ac): C++ EH exception - code e06d7363 (first chance)
(11bc.7ac): Access violation - code c0000005 (first chance)
First chance exceptions are reported before any exception handling.
This exception may be expected and handled.
KERNEL32!RaiseException+0x39:
00000000`7730649d 4881c4c8000000 add rsp,0C8h
Originating from mscorjit, it seems. Does anyone know what the cause of this
could be or how we could aid in debugging the problem further?
Sincerly,
Sune Foldager
Edlund A/S