[fastcall] Fix a 32-bit compare on x64

Bug: chromium:1342020
Change-Id: Ie8e68d06509cb64088c3e88140f5ab0c6494c915
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3747865
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Auto-Submit: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/main@{#81610}
This commit is contained in:
Maya Lekova 2022-07-06 14:48:17 +02:00 committed by V8 LUCI CQ
parent cb57d69404
commit 307dffed3c

View File

@ -2060,7 +2060,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ j(parity_even, &fail, Label::kNear);
// If the input is INT32_MIN, then the conversion succeeds.
__ j(equal, &done, Label::kNear);
__ cmpq(output_reg, Immediate(1));
__ cmpl(output_reg, Immediate(1));
// If the conversion results in INT32_MIN, but the input was not
// INT32_MIN, then the conversion fails.
__ j(no_overflow, &done, Label::kNear);