From c230981fafe12b6dd638f3dd5b9debf9e6ba1776 Mon Sep 17 00:00:00 2001 From: Bruce Forstall Date: Thu, 10 Dec 2020 23:43:28 -0800 Subject: [PATCH] [release/5.0] Fix GC hole with STOREIND of LCL_VAR_ADDR/LCL_FLD_ADDR Backport of (part of) #45818 to release/5.0 Fixes: #45557 Reported by Roslyn. Bad GC info can lead to an unexplained crash that can't easily be found or worked around. Manual, new unit test, CLR outerloop, SuperPMI asm diffs. Low --- src/coreclr/src/jit/emitxarch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/coreclr/src/jit/emitxarch.cpp b/src/coreclr/src/jit/emitxarch.cpp index f21b1170eb83c..bf4eb04398e59 100644 --- a/src/coreclr/src/jit/emitxarch.cpp +++ b/src/coreclr/src/jit/emitxarch.cpp @@ -3113,7 +3113,7 @@ void emitter::emitInsStoreInd(instruction ins, emitAttr attr, GenTreeStoreInd* m } // Updating variable liveness after instruction was emitted - codeGen->genUpdateLife(varNode); + codeGen->genUpdateLife(mem); return; }