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

Side by Side Diff: src/full-codegen/arm/full-codegen-arm.cc

Issue 1376333003: Eliminate no_frame_range data (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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/compiler.cc ('k') | src/full-codegen/arm64/full-codegen-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 #if V8_TARGET_ARCH_ARM 5 #if V8_TARGET_ARCH_ARM
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/codegen.h" 9 #include "src/codegen.h"
10 #include "src/compiler.h"
11 #include "src/debug/debug.h" 10 #include "src/debug/debug.h"
12 #include "src/full-codegen/full-codegen.h" 11 #include "src/full-codegen/full-codegen.h"
13 #include "src/ic/ic.h" 12 #include "src/ic/ic.h"
14 #include "src/parser.h" 13 #include "src/parser.h"
15 #include "src/scopes.h" 14 #include "src/scopes.h"
16 15
17 #include "src/arm/code-stubs-arm.h" 16 #include "src/arm/code-stubs-arm.h"
18 #include "src/arm/macro-assembler-arm.h" 17 #include "src/arm/macro-assembler-arm.h"
19 18
20 namespace v8 { 19 namespace v8 {
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 __ bind(&ok); 134 __ bind(&ok);
136 } 135 }
137 136
138 // Open a frame scope to indicate that there is a frame on the stack. The 137 // Open a frame scope to indicate that there is a frame on the stack. The
139 // MANUAL indicates that the scope shouldn't actually generate code to set up 138 // MANUAL indicates that the scope shouldn't actually generate code to set up
140 // the frame (that is done below). 139 // the frame (that is done below).
141 FrameScope frame_scope(masm_, StackFrame::MANUAL); 140 FrameScope frame_scope(masm_, StackFrame::MANUAL);
142 141
143 info->set_prologue_offset(masm_->pc_offset()); 142 info->set_prologue_offset(masm_->pc_offset());
144 __ Prologue(info->IsCodePreAgingActive()); 143 __ Prologue(info->IsCodePreAgingActive());
145 info->AddNoFrameRange(0, masm_->pc_offset());
146 144
147 { Comment cmnt(masm_, "[ Allocate locals"); 145 { Comment cmnt(masm_, "[ Allocate locals");
148 int locals_count = info->scope()->num_stack_slots(); 146 int locals_count = info->scope()->num_stack_slots();
149 // Generators allocate locals, if any, in context slots. 147 // Generators allocate locals, if any, in context slots.
150 DCHECK(!IsGeneratorFunction(info->literal()->kind()) || locals_count == 0); 148 DCHECK(!IsGeneratorFunction(info->literal()->kind()) || locals_count == 0);
151 if (locals_count > 0) { 149 if (locals_count > 0) {
152 if (locals_count >= 128) { 150 if (locals_count >= 128) {
153 Label ok; 151 Label ok;
154 __ sub(r9, sp, Operand(locals_count * kPointerSize)); 152 __ sub(r9, sp, Operand(locals_count * kPointerSize));
155 __ LoadRoot(r2, Heap::kRealStackLimitRootIndex); 153 __ LoadRoot(r2, Heap::kRealStackLimitRootIndex);
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 __ bind(&ok); 465 __ bind(&ok);
468 466
469 // Make sure that the constant pool is not emitted inside of the return 467 // Make sure that the constant pool is not emitted inside of the return
470 // sequence. 468 // sequence.
471 { Assembler::BlockConstPoolScope block_const_pool(masm_); 469 { Assembler::BlockConstPoolScope block_const_pool(masm_);
472 int32_t arg_count = info_->scope()->num_parameters() + 1; 470 int32_t arg_count = info_->scope()->num_parameters() + 1;
473 int32_t sp_delta = arg_count * kPointerSize; 471 int32_t sp_delta = arg_count * kPointerSize;
474 SetReturnPosition(literal()); 472 SetReturnPosition(literal());
475 // TODO(svenpanne) The code below is sometimes 4 words, sometimes 5! 473 // TODO(svenpanne) The code below is sometimes 4 words, sometimes 5!
476 PredictableCodeSizeScope predictable(masm_, -1); 474 PredictableCodeSizeScope predictable(masm_, -1);
477 int no_frame_start = __ LeaveFrame(StackFrame::JAVA_SCRIPT); 475 __ LeaveFrame(StackFrame::JAVA_SCRIPT);
478 { ConstantPoolUnavailableScope constant_pool_unavailable(masm_); 476 { ConstantPoolUnavailableScope constant_pool_unavailable(masm_);
479 __ add(sp, sp, Operand(sp_delta)); 477 __ add(sp, sp, Operand(sp_delta));
480 __ Jump(lr); 478 __ Jump(lr);
481 info_->AddNoFrameRange(no_frame_start, masm_->pc_offset());
482 } 479 }
483 } 480 }
484 } 481 }
485 } 482 }
486 483
487 484
488 void FullCodeGenerator::StackValueContext::Plug(Variable* var) const { 485 void FullCodeGenerator::StackValueContext::Plug(Variable* var) const {
489 DCHECK(var->IsStackAllocated() || var->IsContextSlot()); 486 DCHECK(var->IsStackAllocated() || var->IsContextSlot());
490 codegen()->GetVar(result_register(), var); 487 codegen()->GetVar(result_register(), var);
491 __ push(result_register()); 488 __ push(result_register());
(...skipping 4777 matching lines...) Expand 10 before | Expand all | Expand 10 after
5269 DCHECK(interrupt_address == 5266 DCHECK(interrupt_address ==
5270 isolate->builtins()->OsrAfterStackCheck()->entry()); 5267 isolate->builtins()->OsrAfterStackCheck()->entry());
5271 return OSR_AFTER_STACK_CHECK; 5268 return OSR_AFTER_STACK_CHECK;
5272 } 5269 }
5273 5270
5274 5271
5275 } // namespace internal 5272 } // namespace internal
5276 } // namespace v8 5273 } // namespace v8
5277 5274
5278 #endif // V8_TARGET_ARCH_ARM 5275 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/compiler.cc ('k') | src/full-codegen/arm64/full-codegen-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698