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

Side by Side Diff: src/arm/deoptimizer-arm.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 | « no previous file | src/arm64/deoptimizer-arm64.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/codegen.h" 5 #include "src/codegen.h"
6 #include "src/deoptimizer.h" 6 #include "src/deoptimizer.h"
7 #include "src/full-codegen/full-codegen.h" 7 #include "src/full-codegen/full-codegen.h"
8 #include "src/register-configuration.h" 8 #include "src/register-configuration.h"
9 #include "src/safepoint-table.h" 9 #include "src/safepoint-table.h"
10 10
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 DCHECK(prev_call_address == NULL || 78 DCHECK(prev_call_address == NULL ||
79 call_address >= prev_call_address + patch_size()); 79 call_address >= prev_call_address + patch_size());
80 DCHECK(call_address + patch_size() <= code->instruction_end()); 80 DCHECK(call_address + patch_size() <= code->instruction_end());
81 #ifdef DEBUG 81 #ifdef DEBUG
82 prev_call_address = call_address; 82 prev_call_address = call_address;
83 #endif 83 #endif
84 } 84 }
85 } 85 }
86 86
87 87
88 void Deoptimizer::FillInputFrame(Address tos, JavaScriptFrame* frame) {
89 // Set the register values. The values are not important as there are no
90 // callee saved registers in JavaScript frames, so all registers are
91 // spilled. Registers fp and sp are set to the correct values though.
92
93 for (int i = 0; i < Register::kNumRegisters; i++) {
94 input_->SetRegister(i, i * 4);
95 }
96 input_->SetRegister(sp.code(), reinterpret_cast<intptr_t>(frame->sp()));
97 input_->SetRegister(fp.code(), reinterpret_cast<intptr_t>(frame->fp()));
98 for (int i = 0; i < DoubleRegister::kMaxNumRegisters; i++) {
99 input_->SetDoubleRegister(i, 0.0);
100 }
101
102 // Fill the frame content from the actual data on the frame.
103 for (unsigned i = 0; i < input_->GetFrameSize(); i += kPointerSize) {
104 input_->SetFrameSlot(i, Memory::uint32_at(tos + i));
105 }
106 }
107
108
109 void Deoptimizer::SetPlatformCompiledStubRegisters( 88 void Deoptimizer::SetPlatformCompiledStubRegisters(
110 FrameDescription* output_frame, CodeStubDescriptor* descriptor) { 89 FrameDescription* output_frame, CodeStubDescriptor* descriptor) {
111 ApiFunction function(descriptor->deoptimization_handler()); 90 ApiFunction function(descriptor->deoptimization_handler());
112 ExternalReference xref(&function, ExternalReference::BUILTIN_CALL, isolate_); 91 ExternalReference xref(&function, ExternalReference::BUILTIN_CALL, isolate_);
113 intptr_t handler = reinterpret_cast<intptr_t>(xref.address()); 92 intptr_t handler = reinterpret_cast<intptr_t>(xref.address());
114 int params = descriptor->GetHandlerParameterCount(); 93 int params = descriptor->GetHandlerParameterCount();
115 output_frame->SetRegister(r0.code(), params); 94 output_frame->SetRegister(r0.code(), params);
116 output_frame->SetRegister(r1.code(), handler); 95 output_frame->SetRegister(r1.code(), handler);
117 } 96 }
118 97
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 void FrameDescription::SetCallerConstantPool(unsigned offset, intptr_t value) { 335 void FrameDescription::SetCallerConstantPool(unsigned offset, intptr_t value) {
357 DCHECK(FLAG_enable_embedded_constant_pool); 336 DCHECK(FLAG_enable_embedded_constant_pool);
358 SetFrameSlot(offset, value); 337 SetFrameSlot(offset, value);
359 } 338 }
360 339
361 340
362 #undef __ 341 #undef __
363 342
364 } // namespace internal 343 } // namespace internal
365 } // namespace v8 344 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/arm64/deoptimizer-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698