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

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

Issue 1278783002: [es6] Use strict arguments objects for destructured parameters (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Doh Created 5 years, 4 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/full-codegen/full-codegen.h ('k') | src/full-codegen/mips/full-codegen-mips.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/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_IA32 7 #if V8_TARGET_ARCH_IA32
8 8
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 int offset = num_parameters * kPointerSize; 313 int offset = num_parameters * kPointerSize;
314 __ lea(edx, 314 __ lea(edx,
315 Operand(ebp, StandardFrameConstants::kCallerSPOffset + offset)); 315 Operand(ebp, StandardFrameConstants::kCallerSPOffset + offset));
316 __ push(edx); 316 __ push(edx);
317 __ push(Immediate(Smi::FromInt(num_parameters))); 317 __ push(Immediate(Smi::FromInt(num_parameters)));
318 // Arguments to ArgumentsAccessStub: 318 // Arguments to ArgumentsAccessStub:
319 // function, receiver address, parameter count. 319 // function, receiver address, parameter count.
320 // The stub will rewrite receiver and parameter count if the previous 320 // The stub will rewrite receiver and parameter count if the previous
321 // stack frame was an arguments adapter frame. 321 // stack frame was an arguments adapter frame.
322 ArgumentsAccessStub::Type type; 322 ArgumentsAccessStub::Type type;
323 if (is_strict(language_mode()) || !is_simple_parameter_list()) { 323 if (is_strict(language_mode()) || !has_simple_parameters()) {
324 type = ArgumentsAccessStub::NEW_STRICT; 324 type = ArgumentsAccessStub::NEW_STRICT;
325 } else if (function()->has_duplicate_parameters()) { 325 } else if (function()->has_duplicate_parameters()) {
326 type = ArgumentsAccessStub::NEW_SLOPPY_SLOW; 326 type = ArgumentsAccessStub::NEW_SLOPPY_SLOW;
327 } else { 327 } else {
328 type = ArgumentsAccessStub::NEW_SLOPPY_FAST; 328 type = ArgumentsAccessStub::NEW_SLOPPY_FAST;
329 } 329 }
330 330
331 ArgumentsAccessStub stub(isolate(), type); 331 ArgumentsAccessStub stub(isolate(), type);
332 __ CallStub(&stub); 332 __ CallStub(&stub);
333 333
(...skipping 5007 matching lines...) Expand 10 before | Expand all | Expand 10 after
5341 Assembler::target_address_at(call_target_address, 5341 Assembler::target_address_at(call_target_address,
5342 unoptimized_code)); 5342 unoptimized_code));
5343 return OSR_AFTER_STACK_CHECK; 5343 return OSR_AFTER_STACK_CHECK;
5344 } 5344 }
5345 5345
5346 5346
5347 } // namespace internal 5347 } // namespace internal
5348 } // namespace v8 5348 } // namespace v8
5349 5349
5350 #endif // V8_TARGET_ARCH_IA32 5350 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/full-codegen/full-codegen.h ('k') | src/full-codegen/mips/full-codegen-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698