diff options
author | chunseoklee <chunseoklee@naver.com> | 2017-12-19 10:41:50 +0900 |
---|---|---|
committer | Jan Vorlicek <janvorli@microsoft.com> | 2017-12-19 02:41:50 +0100 |
commit | 50adfc5195a236a902617b0f7b8b46074fbe4694 (patch) | |
tree | d6f9cd53c9b35f007fe419f7e45f6e2097b92e1e /src | |
parent | fe5d34ba186b224347e08d439f02090413498564 (diff) | |
download | coreclr-50adfc5195a236a902617b0f7b8b46074fbe4694.tar.gz coreclr-50adfc5195a236a902617b0f7b8b46074fbe4694.tar.bz2 coreclr-50adfc5195a236a902617b0f7b8b46074fbe4694.zip |
Enable gdbjit while NI file exist (#15501)
Current gdbjit does not work with NI files.
This patch allows breakpoint to work with NI files when COMPlus_ZapDisable=1
Signed-off-by: chunseok lee <chunseok.lee@samsung.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/vm/gdbjit.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/vm/gdbjit.cpp b/src/vm/gdbjit.cpp index 7554f3ae55..4ab5336f49 100644 --- a/src/vm/gdbjit.cpp +++ b/src/vm/gdbjit.cpp @@ -2576,11 +2576,25 @@ void NotifyGdb::OnMethodPrepared(MethodDesc* methodDescPtr) } #endif + // remove '.ni.dll' or '.ni.exe' suffix from wszModuleFile + LPWSTR pNIExt = const_cast<LPWSTR>(wcsstr(wszModuleFile, W(".ni.exe"))); // where '.ni.exe' start at + if (!pNIExt) + { + pNIExt = const_cast<LPWSTR>(wcsstr(wszModuleFile, W(".ni.dll"))); // where '.ni.dll' start at + } + + if (pNIExt) + { + wcscpy(pNIExt, W(".dll")); + } + if (isListedModule(wszModuleFile)) { bool bEmitted = EmitDebugInfo(elfBuilder, methodDescPtr, pCode, codeSize); bNotify = bNotify || bEmitted; } + + #ifdef FEATURE_GDBJIT_SYMTAB else { |