summaryrefslogtreecommitdiff
path: root/src/debug
diff options
context:
space:
mode:
authorDavid Mason <davmason@microsoft.com>2017-09-18 14:41:48 -0700
committerGitHub <noreply@github.com>2017-09-18 14:41:48 -0700
commit00f316a9194904ca567f6006febb4aa7eac49aa6 (patch)
tree099e44818721316fb8935e0749245aaa5238d750 /src/debug
parent77594c567e80b22ef1b3e14c69adc50c9c163b27 (diff)
downloadcoreclr-00f316a9194904ca567f6006febb4aa7eac49aa6.tar.gz
coreclr-00f316a9194904ca567f6006febb4aa7eac49aa6.tar.bz2
coreclr-00f316a9194904ca567f6006febb4aa7eac49aa6.zip
Change jit notifications so that they pass the native code address. (#14021)
* Change jit notifications so that they pass the native code address. This fixes !bpmd so that it will set the correct breakpoint on tiered jitted methods. * code review feedback * don't handle OnCodeGenerated
Diffstat (limited to 'src/debug')
-rw-r--r--src/debug/daccess/daccess.cpp29
1 files changed, 25 insertions, 4 deletions
diff --git a/src/debug/daccess/daccess.cpp b/src/debug/daccess/daccess.cpp
index 12825e040f..5bfbf6151e 100644
--- a/src/debug/daccess/daccess.cpp
+++ b/src/debug/daccess/daccess.cpp
@@ -4389,6 +4389,7 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
GcEvtArgs pubGcEvtArgs;
ULONG32 notifyType = 0;
DWORD catcherNativeOffset = 0;
+ TADDR nativeCodeLocation = NULL;
DAC_ENTER();
@@ -4451,11 +4452,11 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
break;
}
- case DACNotify::JIT_NOTIFICATION:
+ case DACNotify::JIT_NOTIFICATION2:
{
TADDR methodDescPtr;
- if (DACNotify::ParseJITNotification(exInfo, methodDescPtr))
+ if(DACNotify::ParseJITNotification(exInfo, methodDescPtr, nativeCodeLocation))
{
// Try and find the right appdomain
MethodDesc* methodDesc = PTR_MethodDesc(methodDescPtr);
@@ -4488,7 +4489,7 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
}
break;
}
-
+
case DACNotify::EXCEPTION_NOTIFICATION:
{
TADDR threadPtr;
@@ -4594,6 +4595,13 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
notify4 = NULL;
}
+ IXCLRDataExceptionNotification5* notify5;
+ if (notify->QueryInterface(__uuidof(IXCLRDataExceptionNotification5),
+ (void**)&notify5) != S_OK)
+ {
+ notify5 = NULL;
+ }
+
switch(notifyType)
{
case DACNotify::MODULE_LOAD_NOTIFICATION:
@@ -4604,8 +4612,13 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
notify->OnModuleUnloaded(pubModule);
break;
- case DACNotify::JIT_NOTIFICATION:
+ case DACNotify::JIT_NOTIFICATION2:
notify->OnCodeGenerated(pubMethodInst);
+
+ if (notify5)
+ {
+ notify5->OnCodeGenerated2(pubMethodInst, TO_CDADDR(nativeCodeLocation));
+ }
break;
case DACNotify::EXCEPTION_NOTIFICATION:
@@ -4647,6 +4660,14 @@ ClrDataAccess::TranslateExceptionRecordToNotification(
{
notify3->Release();
}
+ if (notify4)
+ {
+ notify4->Release();
+ }
+ if (notify5)
+ {
+ notify5->Release();
+ }
}
if (pubModule)