COR_IL_MAP 結構COR_IL_MAP Structure

指定函式相關位移中的變更。Specifies changes in the relative offset of a function.

語法Syntax

typedef struct _COR_IL_MAP {  
    ULONG32 oldOffset;
    ULONG32 newOffset;
    BOOL    fAccurate;  
} COR_IL_MAP;  

成員Members

memberMember 描述Description
oldOffset 舊版 Microsoft 中繼語言 (MSIL) 相對於函數開頭的位移。The old Microsoft intermediate language (MSIL) offset relative to the beginning of the function.
newOffset 相對於函數開頭的新 MSIL 位移。The new MSIL offset relative to the beginning of the function.
fAccurate true 如果已知對應是正確的,否則為 falsetrue if the mapping is known to be accurate; otherwise, false.

備註Remarks

對應的格式如下所示:偵錯工具會假設 oldOffset 參考原始、未修改之 msil 程式碼內的 MSIL 位移。The format of the map is as follows: The debugger will assume that oldOffset refers to an MSIL offset within the original, unmodified MSIL code. newOffset參數會參考新檢測程式碼內的對應 MSIL 位移。The newOffset parameter refers to the corresponding MSIL offset within the new, instrumented code.

若要讓逐步執行正常運作,應符合下列需求:For stepping to work properly, the following requirements should be met:

  • 地圖應該以遞增順序排序。The map should be sorted in ascending order.

  • 已檢測的 MSIL 程式碼不應重新排序。Instrumented MSIL code should not be reordered.

  • 不應移除原始 MSIL 程式碼。Original MSIL code should not be removed.

  • 對應應包含專案,以對應程式資料庫 (PDB) 檔中的所有序列點。The map should include entries to map all the sequence points from the program database (PDB) file.

地圖不會插補遺漏的專案。The map does not interpolate missing entries. 下列範例顯示對應和其結果。The following example shows a map and its results.

地圖:Map:

  • 0舊位移,0新位移0 old offset, 0 new offset

  • 5個舊的位移,10個新的位移5 old offset, 10 new offset

  • 9個舊的位移,20個新的位移9 old offset, 20 new offset

結果:Results:

  • 舊的位移0、1、2、3或4將會對應至新的位移0。An old offset of 0, 1, 2, 3, or 4 will be mapped to a new offset of 0.

  • 舊的位移5、6、7或8將會對應至新的位移10。An old offset of 5, 6, 7, or 8 will be mapped to new offset 10.

  • 舊位移9或更高版本將會對應至新的位移20。An old offset of 9 or higher will be mapped to new offset 20.

  • 新的位移0、1、2、3、4、5、6、7、8或9將會對應到舊的位移0。A new offset of 0, 1, 2, 3, 4, 5, 6, 7, 8, or 9 will be mapped to old offset 0.

  • 新的位移10、11、12、13、14、15、16、17、18或19將會對應到舊的位移5。A new offset of 10, 11, 12, 13, 14, 15, 16, 17, 18, or 19 will be mapped to old offset 5.

  • 新的位移20或更高的位移會對應到舊的位移9。A new offset of 20 or higher will be mapped to old offset 9.

規格需求Requirements

平台: 請參閱 系統需求Platforms: See System Requirements.

標頭: Cordebug.h .idl,Corprof.h .idlHeader: CorDebug.idl, CorProf.idl

程式庫: CorGuids.libLibrary: CorGuids.lib

.NET Framework 版本:自 1.0 起可用Available since 1.0.NET Framework Versions: 自 1.0 起可用Available since 1.0

另請參閱See also