Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(205)

Unified Diff: src/full-codegen/ppc/full-codegen-ppc.cc

Issue 1650593002: PPC: Refactor checks for minus zero. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@patch05
Patch Set: Fix typos. Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/crankshaft/ppc/lithium-codegen-ppc.cc ('k') | src/ppc/builtins-ppc.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen/ppc/full-codegen-ppc.cc
diff --git a/src/full-codegen/ppc/full-codegen-ppc.cc b/src/full-codegen/ppc/full-codegen-ppc.cc
index 0abae3d6271892fc18a4ede5d3e7087740b0ca9b..6d7cf8bd459d519e54cf32716929f1a851bbe2a9 100644
--- a/src/full-codegen/ppc/full-codegen-ppc.cc
+++ b/src/full-codegen/ppc/full-codegen-ppc.cc
@@ -3162,22 +3162,7 @@ void FullCodeGenerator::EmitIsMinusZero(CallRuntime* expr) {
&if_false, &fall_through);
__ CheckMap(r3, r4, Heap::kHeapNumberMapRootIndex, if_false, DO_SMI_CHECK);
-#if V8_TARGET_ARCH_PPC64
- __ LoadP(r4, FieldMemOperand(r3, HeapNumber::kValueOffset));
- __ li(r5, Operand(1));
- __ rotrdi(r5, r5, 1); // r5 = 0x80000000_00000000
- __ cmp(r4, r5);
-#else
- __ lwz(r5, FieldMemOperand(r3, HeapNumber::kExponentOffset));
- __ lwz(r4, FieldMemOperand(r3, HeapNumber::kMantissaOffset));
- Label skip;
- __ lis(r0, Operand(SIGN_EXT_IMM16(0x8000)));
- __ cmp(r5, r0);
- __ bne(&skip);
- __ cmpi(r4, Operand::Zero());
- __ bind(&skip);
-#endif
-
+ __ TestHeapNumberIsMinusZero(r3, r4, r5);
PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
Split(eq, if_true, if_false, fall_through);
« no previous file with comments | « src/crankshaft/ppc/lithium-codegen-ppc.cc ('k') | src/ppc/builtins-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698