Commit 6e479fb8 authored by Junliang Yan's avatar Junliang Yan Committed by Commit Bot

ppc: [liftoff] implement emit_i64_eqz/set_cond

Change-Id: Idf927a4c8bc5e4751e5e8913fe9912fd44001190
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2857854Reviewed-by: 's avatarMilad Fa <mfarazma@redhat.com>
Commit-Queue: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/master@{#74263}
parent 3b2552de
......@@ -645,13 +645,28 @@ void LiftoffAssembler::emit_i32_set_cond(LiftoffCondition liftoff_cond,
}
void LiftoffAssembler::emit_i64_eqz(Register dst, LiftoffRegister src) {
bailout(kUnsupportedArchitecture, "emit_i64_eqz");
Label done;
cmpi(src.gp(), Operand(0));
mov(dst, Operand(1));
beq(&done);
mov(dst, Operand::Zero());
bind(&done);
}
void LiftoffAssembler::emit_i64_set_cond(LiftoffCondition liftoff_cond,
Register dst, LiftoffRegister lhs,
LiftoffRegister rhs) {
bailout(kUnsupportedArchitecture, "emit_i64_set_cond");
bool use_signed = liftoff::UseSignedOp(liftoff_cond);
if (use_signed) {
cmp(lhs.gp(), rhs.gp());
} else {
cmpl(lhs.gp(), rhs.gp());
}
Label done;
mov(dst, Operand(1));
b(liftoff::ToCondition(liftoff_cond), &done);
mov(dst, Operand::Zero());
bind(&done);
}
void LiftoffAssembler::emit_f32_set_cond(LiftoffCondition liftoff_cond,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment