diff options
author | Jan Vorlicek <janvorli@microsoft.com> | 2018-12-07 10:32:59 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-07 10:32:59 +0100 |
commit | add9f313447c44db85944cbff0d633f8852b5b9f (patch) | |
tree | 0df6a9239eb07af236508a14963fd4e934b15d11 | |
parent | 35b5555b96b57e9f5a969580abb5dfdfeb735732 (diff) | |
download | coreclr-add9f313447c44db85944cbff0d633f8852b5b9f.tar.gz coreclr-add9f313447c44db85944cbff0d633f8852b5b9f.tar.bz2 coreclr-add9f313447c44db85944cbff0d633f8852b5b9f.zip |
Fix SOS thread statics display (#21426)
I've noticed that when dumping an object with thread locals using SOS
dumpobj command, I never get the thread locals. I've stepped through the
code in SOS that displays thread statics and found that for some strange
reason, it dismisses threads where DomainLocalModule doesn't have
"initialized" flag set for the given class. However, when runtime
accesses thread statics, it just checks "allocated" flag set for the
given class in the ThreadLocalModule. Removing the extra check for
DomainLocalModule fixed the problem and now thread statics are displayed
properly.
-rw-r--r-- | src/ToolBox/SOS/Strike/util.cpp | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/ToolBox/SOS/Strike/util.cpp b/src/ToolBox/SOS/Strike/util.cpp index 3abe606d69..5533017a9f 100644 --- a/src/ToolBox/SOS/Strike/util.cpp +++ b/src/ToolBox/SOS/Strike/util.cpp @@ -1327,18 +1327,6 @@ void DisplayThreadStatic(DacpModuleData* pModule, DacpMethodTableData* pMT, Dacp { CLRDATA_ADDRESS appDomainAddr = vThread.domain; - // Get the DLM (we need this to check the ClassInit flags). - // It's annoying that we have to issue one request for - // domain-neutral modules and domain-specific modules. - DacpDomainLocalModuleData vDomainLocalModule; - if (g_sos->GetDomainLocalModuleDataFromModule(pMT->Module, &vDomainLocalModule) != S_OK) - { - // Not initialized, go to next thread - // and continue looping - CurThread = vThread.nextThread; - continue; - } - // Get the TLM DacpThreadLocalModuleData vThreadLocalModule; if (g_sos->GetThreadLocalModuleData(CurThread, (int)dwModuleIndex, &vThreadLocalModule) != S_OK) @@ -1361,17 +1349,6 @@ void DisplayThreadStatic(DacpModuleData* pModule, DacpMethodTableData* pMT, Dacp continue; } - Flags = 0; - GetDLMFlags(&vDomainLocalModule, pMT, &Flags); - - if ((Flags&1) == 0) - { - // Not initialized, go to next thread - // and continue looping - CurThread = vThread.nextThread; - continue; - } - ExtOut(" %x:", vThread.osThreadId); DisplayDataMember(pFD, dwTmp, FALSE); } |