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

Side by Side Diff: src/x64/deoptimizer-x64.cc

Issue 1698743002: Make the frame inspector use TranslatedState rather than the full deoptimizer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Address review comments, changed some DCHECKs to CHECKs Created 4 years, 10 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/deoptimizer-ppc.cc ('k') | src/x87/deoptimizer-x87.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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/codegen.h" 7 #include "src/codegen.h"
8 #include "src/deoptimizer.h" 8 #include "src/deoptimizer.h"
9 #include "src/full-codegen/full-codegen.h" 9 #include "src/full-codegen/full-codegen.h"
10 #include "src/register-configuration.h" 10 #include "src/register-configuration.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 DCHECK(prev_call_address == NULL || 81 DCHECK(prev_call_address == NULL ||
82 call_address >= prev_call_address + patch_size()); 82 call_address >= prev_call_address + patch_size());
83 DCHECK(call_address + patch_size() <= code->instruction_end()); 83 DCHECK(call_address + patch_size() <= code->instruction_end());
84 #ifdef DEBUG 84 #ifdef DEBUG
85 prev_call_address = call_address; 85 prev_call_address = call_address;
86 #endif 86 #endif
87 } 87 }
88 } 88 }
89 89
90 90
91 void Deoptimizer::FillInputFrame(Address tos, JavaScriptFrame* frame) {
92 // Set the register values. The values are not important as there are no
93 // callee saved registers in JavaScript frames, so all registers are
94 // spilled. Registers rbp and rsp are set to the correct values though.
95 for (int i = 0; i < Register::kNumRegisters; i++) {
96 input_->SetRegister(i, i * 4);
97 }
98 input_->SetRegister(rsp.code(), reinterpret_cast<intptr_t>(frame->sp()));
99 input_->SetRegister(rbp.code(), reinterpret_cast<intptr_t>(frame->fp()));
100 for (int i = 0; i < DoubleRegister::kMaxNumRegisters; i++) {
101 input_->SetDoubleRegister(i, 0.0);
102 }
103
104 // Fill the frame content from the actual data on the frame.
105 for (unsigned i = 0; i < input_->GetFrameSize(); i += kPointerSize) {
106 input_->SetFrameSlot(i, Memory::uintptr_at(tos + i));
107 }
108 }
109
110
111 void Deoptimizer::SetPlatformCompiledStubRegisters( 91 void Deoptimizer::SetPlatformCompiledStubRegisters(
112 FrameDescription* output_frame, CodeStubDescriptor* descriptor) { 92 FrameDescription* output_frame, CodeStubDescriptor* descriptor) {
113 intptr_t handler = 93 intptr_t handler =
114 reinterpret_cast<intptr_t>(descriptor->deoptimization_handler()); 94 reinterpret_cast<intptr_t>(descriptor->deoptimization_handler());
115 int params = descriptor->GetHandlerParameterCount(); 95 int params = descriptor->GetHandlerParameterCount();
116 output_frame->SetRegister(rax.code(), params); 96 output_frame->SetRegister(rax.code(), params);
117 output_frame->SetRegister(rbx.code(), handler); 97 output_frame->SetRegister(rbx.code(), handler);
118 } 98 }
119 99
120 100
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 } 333 }
354 334
355 335
356 #undef __ 336 #undef __
357 337
358 338
359 } // namespace internal 339 } // namespace internal
360 } // namespace v8 340 } // namespace v8
361 341
362 #endif // V8_TARGET_ARCH_X64 342 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/ppc/deoptimizer-ppc.cc ('k') | src/x87/deoptimizer-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698