ppc: [liftoff] implement smi_check

Change-Id: Ifc75747a179486b6fe173c2d34f72f66c1918d88
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3124813
Reviewed-by: Milad Fa <mfarazma@redhat.com>
Commit-Queue: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/main@{#76544}
This commit is contained in:
Junliang Yan 2021-08-27 14:57:58 -04:00 committed by V8 LUCI CQ
parent 938eead7b8
commit 4c5a2b1255

View File

@ -1222,7 +1222,9 @@ void LiftoffAssembler::LoadTransform(LiftoffRegister dst, Register src_addr,
void LiftoffAssembler::emit_smi_check(Register obj, Label* target,
SmiCheckMode mode) {
bailout(kUnsupportedArchitecture, "emit_smi_check");
TestIfSmi(obj, r0);
Condition condition = mode == kJumpOnSmi ? eq : ne;
b(condition, target, cr0); // branch if SMI
}
void LiftoffAssembler::LoadLane(LiftoffRegister dst, LiftoffRegister src,