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

Side by Side Diff: src/frames.cc

Issue 1405673003: provides a mechanism for optimizing compilers to select the different Register configuration. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add the TODO comments. Created 5 years, 2 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/crankshaft/lithium-allocator.cc ('k') | src/ia32/deoptimizer-ia32.cc » ('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/frames.h" 5 #include "src/frames.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/ast.h" 9 #include "src/ast.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 648 matching lines...) Expand 10 before | Expand all | Expand 10 after
659 if (safepoint_entry.argument_count() > 0) { 659 if (safepoint_entry.argument_count() > 0) {
660 v->VisitPointers(parameters_base, 660 v->VisitPointers(parameters_base,
661 parameters_base + safepoint_entry.argument_count()); 661 parameters_base + safepoint_entry.argument_count());
662 parameters_base += safepoint_entry.argument_count(); 662 parameters_base += safepoint_entry.argument_count();
663 } 663 }
664 664
665 // Skip saved double registers. 665 // Skip saved double registers.
666 if (safepoint_entry.has_doubles()) { 666 if (safepoint_entry.has_doubles()) {
667 // Number of doubles not known at snapshot time. 667 // Number of doubles not known at snapshot time.
668 DCHECK(!isolate()->serializer_enabled()); 668 DCHECK(!isolate()->serializer_enabled());
669 parameters_base += RegisterConfiguration::ArchDefault() 669 parameters_base +=
670 ->num_allocatable_double_registers() * 670 RegisterConfiguration::ArchDefault(RegisterConfiguration::CRANKSHAFT)
671 kDoubleSize / kPointerSize; 671 ->num_allocatable_double_registers() *
672 kDoubleSize / kPointerSize;
672 } 673 }
673 674
674 // Visit the registers that contain pointers if any. 675 // Visit the registers that contain pointers if any.
675 if (safepoint_entry.HasRegisters()) { 676 if (safepoint_entry.HasRegisters()) {
676 for (int i = kNumSafepointRegisters - 1; i >=0; i--) { 677 for (int i = kNumSafepointRegisters - 1; i >=0; i--) {
677 if (safepoint_entry.HasRegisterAt(i)) { 678 if (safepoint_entry.HasRegisterAt(i)) {
678 int reg_stack_index = MacroAssembler::SafepointRegisterStackIndex(i); 679 int reg_stack_index = MacroAssembler::SafepointRegisterStackIndex(i);
679 v->VisitPointer(parameters_base + reg_stack_index); 680 v->VisitPointer(parameters_base + reg_stack_index);
680 } 681 }
681 } 682 }
(...skipping 910 matching lines...) Expand 10 before | Expand all | Expand 10 after
1592 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) { 1593 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) {
1593 StackFrame* frame = AllocateFrameCopy(it.frame(), zone); 1594 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1594 list.Add(frame, zone); 1595 list.Add(frame, zone);
1595 } 1596 }
1596 return list.ToVector(); 1597 return list.ToVector();
1597 } 1598 }
1598 1599
1599 1600
1600 } // namespace internal 1601 } // namespace internal
1601 } // namespace v8 1602 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/lithium-allocator.cc ('k') | src/ia32/deoptimizer-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698