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

Side by Side Diff: src/x64/macro-assembler-x64.cc

Issue 1115973005: Revert of Collect type feedback on result of Math.[round|ceil|floor] (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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/x64/macro-assembler-x64.h ('k') | test/mjsunit/math-ceil-minus-zero.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_X64 7 #if V8_TARGET_ARCH_X64
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/base/division-by-constant.h" 10 #include "src/base/division-by-constant.h"
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 726
727 727
728 void MacroAssembler::GetBuiltinEntry(Register target, Builtins::JavaScript id) { 728 void MacroAssembler::GetBuiltinEntry(Register target, Builtins::JavaScript id) {
729 DCHECK(!target.is(rdi)); 729 DCHECK(!target.is(rdi));
730 // Load the JavaScript builtin function from the builtins object. 730 // Load the JavaScript builtin function from the builtins object.
731 GetBuiltinFunction(rdi, id); 731 GetBuiltinFunction(rdi, id);
732 movp(target, FieldOperand(rdi, JSFunction::kCodeEntryOffset)); 732 movp(target, FieldOperand(rdi, JSFunction::kCodeEntryOffset));
733 } 733 }
734 734
735 735
736 void MacroAssembler::BranchIfNotBuiltin(Register function, Register temp,
737 BuiltinFunctionId id, Label* miss) {
738 movp(temp, FieldOperand(function, JSFunction::kSharedFunctionInfoOffset));
739 movp(temp, FieldOperand(temp, SharedFunctionInfo::kFunctionDataOffset));
740 Cmp(temp, Smi::FromInt(id));
741 j(not_equal, miss);
742 }
743
744
745 #define REG(Name) { kRegister_ ## Name ## _Code } 736 #define REG(Name) { kRegister_ ## Name ## _Code }
746 737
747 static const Register saved_regs[] = { 738 static const Register saved_regs[] = {
748 REG(rax), REG(rcx), REG(rdx), REG(rbx), REG(rbp), REG(rsi), REG(rdi), REG(r8), 739 REG(rax), REG(rcx), REG(rdx), REG(rbx), REG(rbp), REG(rsi), REG(rdi), REG(r8),
749 REG(r9), REG(r10), REG(r11) 740 REG(r9), REG(r10), REG(r11)
750 }; 741 };
751 742
752 #undef REG 743 #undef REG
753 744
754 static const int kNumberOfSavedRegs = sizeof(saved_regs) / sizeof(Register); 745 static const int kNumberOfSavedRegs = sizeof(saved_regs) / sizeof(Register);
(...skipping 4344 matching lines...) Expand 10 before | Expand all | Expand 10 after
5099 if (mag.shift > 0) sarl(rdx, Immediate(mag.shift)); 5090 if (mag.shift > 0) sarl(rdx, Immediate(mag.shift));
5100 movl(rax, dividend); 5091 movl(rax, dividend);
5101 shrl(rax, Immediate(31)); 5092 shrl(rax, Immediate(31));
5102 addl(rdx, rax); 5093 addl(rdx, rax);
5103 } 5094 }
5104 5095
5105 5096
5106 } } // namespace v8::internal 5097 } } // namespace v8::internal
5107 5098
5108 #endif // V8_TARGET_ARCH_X64 5099 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.h ('k') | test/mjsunit/math-ceil-minus-zero.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698