Skip to content

Commit

Permalink
[JIT] Remove captureposarg_n
Browse files Browse the repository at this point in the history
MVM_args_get_pos_num returns a MVMArgInfo struct as a value, and the ABI
of doing so is underdocumented and inconsistent between POSIX and Win64.
So what worked on POSIX didn't work on windows.
These functions need to be cleaned up for the benefit of the JIT.
  • Loading branch information
bdw committed Jul 30, 2018
1 parent 936dab0 commit 21ea40f
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 21 deletions.
1 change: 0 additions & 1 deletion src/jit/graph.c
Expand Up @@ -1701,7 +1701,6 @@ static MVMint32 consume_ins(MVMThreadContext *tc, MVMJitGraph *jg,
case MVM_OP_capturehasnameds:
case MVM_OP_captureposarg:
case MVM_OP_captureposarg_i:
case MVM_OP_captureposarg_n:
case MVM_OP_captureposarg_s:
case MVM_OP_captureexistsnamed:
case MVM_OP_capturenamedshash:
Expand Down
20 changes: 0 additions & 20 deletions src/jit/x64/emit.dasc
Expand Up @@ -993,26 +993,6 @@ void MVM_jit_emit_primitive(MVMThreadContext *tc, MVMJitCompiler *compiler, MVMJ
|2:
break;
}
case MVM_OP_captureposarg_n: {
MVMint16 dst = ins->operands[0].reg.orig;
MVMint16 src = ins->operands[1].reg.orig;
MVMint16 pos = ins->operands[2].reg.orig;
| mov TMP5, qword WORK[src];
| test_type_object TMP5;
| jnz >1;
| cmp_repr_id TMP5, TMP6, MVM_REPR_ID_MVMCallCapture;
| jne >1;
| mov ARG1, TC;
| mov ARG2, aword CAPTURE:TMP5->body.apc;
| mov ARG3, qword WORK[pos];
| callp &MVM_args_get_pos_num;
| mov WORK[dst], RV;
| jmp >2;
|1:
| throw_adhoc "captureposarg_n needs a MVMCallCapture";
|2:
break;
}
case MVM_OP_captureposarg_s: {
MVMint16 dst = ins->operands[0].reg.orig;
MVMint16 src = ins->operands[1].reg.orig;
Expand Down

0 comments on commit 21ea40f

Please sign in to comment.