Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Andreenko <seandree@microsoft.com>2021-06-02 22:02:44 +0300
committerGitHub <noreply@github.com>2021-06-02 22:02:44 +0300
commit7a4f8996b1ecbac5d3f71a0c2b9023cf06e95c84 (patch)
tree79212650fdc9b5d5f5ea89d4b693de34e2e6c4a8 /src/coreclr/ToolBox
parent0aa8ca02d6d0d38d0ace23413b46f685ac1aac4a (diff)
Fix SPMI dump. (#53586)
* Fix SPMI dump. * more fixes
Diffstat (limited to 'src/coreclr/ToolBox')
-rw-r--r--src/coreclr/ToolBox/superpmi/superpmi-shared/lightweightmap.h2
-rw-r--r--src/coreclr/ToolBox/superpmi/superpmi-shared/methodcontext.cpp3
-rw-r--r--src/coreclr/ToolBox/superpmi/superpmi-shared/spmidumphelper.h1
3 files changed, 5 insertions, 1 deletions
diff --git a/src/coreclr/ToolBox/superpmi/superpmi-shared/lightweightmap.h b/src/coreclr/ToolBox/superpmi/superpmi-shared/lightweightmap.h
index 23e0e2357ec..ed06e9fac4d 100644
--- a/src/coreclr/ToolBox/superpmi/superpmi-shared/lightweightmap.h
+++ b/src/coreclr/ToolBox/superpmi/superpmi-shared/lightweightmap.h
@@ -157,7 +157,7 @@ public:
return -1;
}
- void Unlock() // did you really mean to use this?
+ void Unlock()
{
locked = false;
}
diff --git a/src/coreclr/ToolBox/superpmi/superpmi-shared/methodcontext.cpp b/src/coreclr/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
index 238a50494d6..28c8d3f1612 100644
--- a/src/coreclr/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
+++ b/src/coreclr/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
@@ -4807,6 +4807,7 @@ void MethodContext::dmpGetStringLiteral(DLD key, DD value)
{
printf("GetStringLiteral key mod-%016llX tok-%08X, result-%s, len-%u", key.A, key.B,
GetStringLiteral->GetBuffer(value.B), value.A);
+ GetStringLiteral->Unlock();
}
const char16_t* MethodContext::repGetStringLiteral(CORINFO_MODULE_HANDLE module, unsigned metaTOK, int* length)
@@ -5468,6 +5469,7 @@ void MethodContext::dmpAllocPgoInstrumentationBySchema(DWORDLONG key, const Agno
printf(" %u-{Offset %016llX ILOffset %u Kind %u(0x%x) Count %u Other %u}\n",
i, pBuf[i].Offset, pBuf[i].ILOffset, pBuf[i].InstrumentationKind, pBuf[i].InstrumentationKind, pBuf[i].Count, pBuf[i].Other);
}
+ AllocPgoInstrumentationBySchema->Unlock();
}
printf("}");
}
@@ -5637,6 +5639,7 @@ void MethodContext::dmpGetPgoInstrumentationResults(DWORDLONG key, const Agnosti
printf("}\n");
}
+ GetPgoInstrumentationResults->Unlock();
}
printf("} data_index-%u", value.data_index);
}
diff --git a/src/coreclr/ToolBox/superpmi/superpmi-shared/spmidumphelper.h b/src/coreclr/ToolBox/superpmi/superpmi-shared/spmidumphelper.h
index ad6ba7beda7..4dc1f28991a 100644
--- a/src/coreclr/ToolBox/superpmi/superpmi-shared/spmidumphelper.h
+++ b/src/coreclr/ToolBox/superpmi/superpmi-shared/spmidumphelper.h
@@ -139,6 +139,7 @@ inline std::string SpmiDumpHelper::DumpPSig(
pbuf += cch;
sizeOfBuffer -= cch;
}
+ buffers->Unlock();
}
return std::string(buffer);