Skip to content

Commit 9018aae

Browse files
committed
OS#17497699: Re-enable pinning of types referenced in monomorphic property guards
1 parent 40d261b commit 9018aae

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/Backend/Lower.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7573,9 +7573,10 @@ Lowerer::GenerateCachedTypeCheck(IR::Instr *instrChk, IR::PropertySymOpnd *prope
75737573
// as long as there are other objects with types equivalent on the properties referenced by this code. The type is kept alive until entry point
75747574
// installation by the JIT transfer data, and after that by the equivalent type cache, so it will stay alive unless or until it gets evicted
75757575
// from the cache.
7576-
if (directCheckType != nullptr)
7576+
if (!doEquivTypeCheck)
75777577
{
7578-
PinTypeRef(directCheckType, directCheckType.t, instrChk, propertySymOpnd->m_sym->AsPropertySym()->m_propertyId);
7578+
Assert(monoType != nullptr);
7579+
PinTypeRef(monoType, monoType.t, instrChk, propertySymOpnd->m_sym->AsPropertySym()->m_propertyId);
75797580
}
75807581

75817582
return typeOpnd;

0 commit comments

Comments
 (0)