Skip to content

Commit

Permalink
Handle some further object read ops in EA
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed Apr 13, 2019
1 parent 5b847bd commit 4579a30
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/spesh/pea.c
Expand Up @@ -843,6 +843,10 @@ static MVMuint32 analyze(MVMThreadContext *tc, MVMSpeshGraph *g, GraphState *gs)
}
break;
}
case MVM_OP_sp_get_o:
case MVM_OP_sp_get_i64:
case MVM_OP_sp_get_n:
case MVM_OP_sp_get_s:
case MVM_OP_sp_p6oget_i:
case MVM_OP_sp_p6oget_n:
case MVM_OP_sp_p6oget_s:
Expand All @@ -855,8 +859,14 @@ static MVMuint32 analyze(MVMThreadContext *tc, MVMSpeshGraph *g, GraphState *gs)
opcode == MVM_OP_sp_p6ogetvc_o ||
opcode == MVM_OP_sp_p6ogetvt_o;
if (allocation_tracked(alloc)) {
MVMint32 is_p6o_op = opcode != MVM_OP_sp_get_o &&
opcode != MVM_OP_sp_get_i64 &&
opcode != MVM_OP_sp_get_n &&
opcode != MVM_OP_sp_get_s;
MVMuint16 hypothetical_reg = attribute_offset_to_reg(tc, alloc,
ins->operands[2].lit_i16);
is_p6o_op
? ins->operands[2].lit_i16
: ins->operands[2].lit_i16 - sizeof(MVMObject));
Transformation *tran = MVM_spesh_alloc(tc, g, sizeof(Transformation));
tran->allocation = alloc;
tran->transform = TRANSFORM_GETATTR_TO_SET;
Expand Down

0 comments on commit 4579a30

Please sign in to comment.