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

Side by Side Diff: src/s390/code-stubs-s390.cc

Issue 2167273003: PPC/s390: [arm] Fix infinite loop in Math.pow(2,2147483648). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 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 unified diff | Download patch
« no previous file with comments | « src/ppc/code-stubs-ppc.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_S390 5 #if V8_TARGET_ARCH_S390
6 6
7 #include "src/code-stubs.h" 7 #include "src/code-stubs.h"
8 #include "src/api-arguments.h" 8 #include "src/api-arguments.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after
769 __ LoadComplementRR(scratch, scratch); 769 __ LoadComplementRR(scratch, scratch);
770 __ bind(&positive_exponent); 770 __ bind(&positive_exponent);
771 771
772 Label while_true, no_carry, loop_end; 772 Label while_true, no_carry, loop_end;
773 __ bind(&while_true); 773 __ bind(&while_true);
774 __ mov(scratch2, Operand(1)); 774 __ mov(scratch2, Operand(1));
775 __ AndP(scratch2, scratch); 775 __ AndP(scratch2, scratch);
776 __ beq(&no_carry, Label::kNear); 776 __ beq(&no_carry, Label::kNear);
777 __ mdbr(double_result, double_scratch); 777 __ mdbr(double_result, double_scratch);
778 __ bind(&no_carry); 778 __ bind(&no_carry);
779 __ ShiftRightArithP(scratch, scratch, Operand(1)); 779 __ ShiftRightP(scratch, scratch, Operand(1));
780 __ LoadAndTestP(scratch, scratch);
780 __ beq(&loop_end, Label::kNear); 781 __ beq(&loop_end, Label::kNear);
781 __ mdbr(double_scratch, double_scratch); 782 __ mdbr(double_scratch, double_scratch);
782 __ b(&while_true); 783 __ b(&while_true);
783 __ bind(&loop_end); 784 __ bind(&loop_end);
784 785
785 __ CmpP(exponent, Operand::Zero()); 786 __ CmpP(exponent, Operand::Zero());
786 __ bge(&done); 787 __ bge(&done);
787 788
788 // get 1/double_result: 789 // get 1/double_result:
789 __ ldr(double_scratch, double_result); 790 __ ldr(double_scratch, double_result);
(...skipping 4601 matching lines...) Expand 10 before | Expand all | Expand 10 after
5391 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref, 5392 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref,
5392 kStackUnwindSpace, NULL, return_value_operand, NULL); 5393 kStackUnwindSpace, NULL, return_value_operand, NULL);
5393 } 5394 }
5394 5395
5395 #undef __ 5396 #undef __
5396 5397
5397 } // namespace internal 5398 } // namespace internal
5398 } // namespace v8 5399 } // namespace v8
5399 5400
5400 #endif // V8_TARGET_ARCH_S390 5401 #endif // V8_TARGET_ARCH_S390
OLDNEW
« no previous file with comments | « src/ppc/code-stubs-ppc.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698