Skip to content

Commit

Permalink
Restore erroneously removed encoding of the argument count in a gener…
Browse files Browse the repository at this point in the history
…ic method instantiation (#98825)

Users of the multicore jit feature would encounter silent encoding failures while recording profiles due to a defect in our encoding for generic method instances that would make them impossible to decode later. This PR fixes the encoding so that newly-recorded profiles will not be corrupt.

Co-authored-by: Katelyn Gadd <kg@luminance.org>
github-actions[bot] and kg authored Mar 6, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 2760222 commit e398dd6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/coreclr/vm/zapsig.cpp
Original file line number Diff line number Diff line change
@@ -1350,6 +1350,9 @@ BOOL ZapSig::EncodeMethod(
else
{
Instantiation inst = pMethod->GetMethodInstantiation();

pSigBuilder->AppendData(inst.GetNumArgs());

for (DWORD i = 0; i < inst.GetNumArgs(); i++)
{
TypeHandle t = inst[i];

0 comments on commit e398dd6

Please sign in to comment.