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

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

Issue 2445703002: Don't call FastNewFunctionContextStub if context is bigger than kMaxRegularHeapObjectSize. (Closed)
Patch Set: Created 4 years, 1 month 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/full-codegen/ppc/full-codegen-ppc.cc ('k') | src/full-codegen/x64/full-codegen-x64.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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_S390 5 #if V8_TARGET_ARCH_S390
6 6
7 #include "src/full-codegen/full-codegen.h" 7 #include "src/full-codegen/full-codegen.h"
8 #include "src/ast/compile-time-value.h" 8 #include "src/ast/compile-time-value.h"
9 #include "src/ast/scopes.h" 9 #include "src/ast/scopes.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 __ Push(info->scope()->scope_info()); 205 __ Push(info->scope()->scope_info());
206 __ CallRuntime(Runtime::kNewScriptContext); 206 __ CallRuntime(Runtime::kNewScriptContext);
207 PrepareForBailoutForId(BailoutId::ScriptContext(), 207 PrepareForBailoutForId(BailoutId::ScriptContext(),
208 BailoutState::TOS_REGISTER); 208 BailoutState::TOS_REGISTER);
209 // The new target value is not used, clobbering is safe. 209 // The new target value is not used, clobbering is safe.
210 DCHECK_NULL(info->scope()->new_target_var()); 210 DCHECK_NULL(info->scope()->new_target_var());
211 } else { 211 } else {
212 if (info->scope()->new_target_var() != nullptr) { 212 if (info->scope()->new_target_var() != nullptr) {
213 __ push(r5); // Preserve new target. 213 __ push(r5); // Preserve new target.
214 } 214 }
215 FastNewFunctionContextStub stub(isolate()); 215 if (slots <= FastNewFunctionContextStub::kMaximumSlots) {
216 __ mov(FastNewFunctionContextDescriptor::SlotsRegister(), Operand(slots)); 216 FastNewFunctionContextStub stub(isolate());
217 __ CallStub(&stub); 217 __ mov(FastNewFunctionContextDescriptor::SlotsRegister(),
218 // Result of FastNewFunctionContextStub is always in new space. 218 Operand(slots));
219 need_write_barrier = false; 219 __ CallStub(&stub);
220 // Result of FastNewFunctionContextStub is always in new space.
221 need_write_barrier = false;
222 } else {
223 __ push(r3);
224 __ CallRuntime(Runtime::kNewFunctionContext);
225 }
220 if (info->scope()->new_target_var() != nullptr) { 226 if (info->scope()->new_target_var() != nullptr) {
221 __ pop(r5); // Preserve new target. 227 __ pop(r5); // Preserve new target.
222 } 228 }
223 } 229 }
224 function_in_register_r3 = false; 230 function_in_register_r3 = false;
225 // Context is returned in r2. It replaces the context passed to us. 231 // Context is returned in r2. It replaces the context passed to us.
226 // It's saved in the stack and kept live in cp. 232 // It's saved in the stack and kept live in cp.
227 __ LoadRR(cp, r2); 233 __ LoadRR(cp, r2);
228 __ StoreP(r2, MemOperand(fp, StandardFrameConstants::kContextOffset)); 234 __ StoreP(r2, MemOperand(fp, StandardFrameConstants::kContextOffset));
229 // Copy any necessary parameters into the context. 235 // Copy any necessary parameters into the context.
(...skipping 3309 matching lines...) Expand 10 before | Expand all | Expand 10 after
3539 DCHECK(kOSRBranchInstruction == br_instr); 3545 DCHECK(kOSRBranchInstruction == br_instr);
3540 3546
3541 DCHECK(interrupt_address == 3547 DCHECK(interrupt_address ==
3542 isolate->builtins()->OnStackReplacement()->entry()); 3548 isolate->builtins()->OnStackReplacement()->entry());
3543 return ON_STACK_REPLACEMENT; 3549 return ON_STACK_REPLACEMENT;
3544 } 3550 }
3545 3551
3546 } // namespace internal 3552 } // namespace internal
3547 } // namespace v8 3553 } // namespace v8
3548 #endif // V8_TARGET_ARCH_S390 3554 #endif // V8_TARGET_ARCH_S390
OLDNEW
« no previous file with comments | « src/full-codegen/ppc/full-codegen-ppc.cc ('k') | src/full-codegen/x64/full-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698