SetILInstrumentedCodeMap may cause access violation (310833)



The information in this article applies to:

  • Microsoft Visual C++ .NET (2002)
  • Microsoft .NET Framework 1.0
  • Microsoft Visual C++ .NET (2003)
  • Microsoft Visual C++ 2005 Express Edition

This article was previously published under Q310833

SYMPTOMS

ICorProfilerInfo::SetILInstrumentedCodeMap may cause an access violation in the managed application that is being profiled if it is called from a JITCompilationStarted callback.

CAUSE

The fStartJit flag is set to FALSE when ICorProfilerInfo::SetILInstrumentedCodeMap is called the first time.

RESOLUTION

To avoid this problem, always set the fStartJit flag to TRUE when SetILInstrumentedCodeMap is called for the first time. On any subsequent calls, set it to TRUE on a per method basis.

STATUS

This behavior is by design.

REFERENCES

For additional information, click the article number below to view the article in the Microsoft Knowledge Base:

309551 INFO: CLR Profiling Services Problems


Modification Type:MajorLast Reviewed:1/11/2006
Keywords:kbtshoot kbPerformanceTool kbprb KB310833 kbAudDeveloper