Skip to content

Commit

Permalink
Merge pull request #1573 from MoarVM/fix-pea-segfaults
Browse files Browse the repository at this point in the history
Fix uninitialized registers after deopt from dispatch guards
  • Loading branch information
jnthn committed Oct 22, 2021
2 parents 5c6fd3b + b92ca73 commit 8c7b734
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/spesh/optimize.c
Expand Up @@ -1167,6 +1167,12 @@ MVMuint32 find_cache_offset(MVMThreadContext *tc, MVMSpeshIns *ins) {
MVMint32 find_predeopt_index(MVMThreadContext *tc, MVMSpeshIns *ins) {
while (ins) {
MVMSpeshAnn *ann = ins->annotations;
while (ann) {
if (ann->type == MVM_SPESH_ANN_DEOPT_SYNTH)
return ann->data.deopt_idx;
ann = ann->next;
}
ann = ins->annotations;
while (ann) {
if (ann->type == MVM_SPESH_ANN_DEOPT_PRE_INS)
return ann->data.deopt_idx;
Expand Down

0 comments on commit 8c7b734

Please sign in to comment.