From 940f225405ed5021d45c5fa1ddec232d4101577e Mon Sep 17 00:00:00 2001 From: sfja Date: Mon, 16 Nov 2026 22:29:57 +0100 Subject: [PATCH] don't bypass wrt plt reg --- isel.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/isel.c b/isel.c index 3304f01..a169ff0 100644 --- a/isel.c +++ b/isel.c @@ -238,14 +238,13 @@ static void lower_inst(L* l, IrInst* inst) }); } - assert(inst->call.expr->ty == IrInst_Val - && inst->call.expr->val->ty == IrVal_Fn); - push_inst(l, (X86Inst) { - .ty = X86InstTy_CallWrtPlt, - .op1 = { .ty = X86Operand_IdentRelWrtPlt, - .ident = inst->call.expr->val->fn->ident }, + .ty = X86InstTy_CallR8, + .op1 = { + .ty = X86Operand_VReg, + .reg = *expr_reg, + }, }); push_inst(l, (X86Inst) {