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

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

Issue 919643008: Remove --experimental-classes flag and related dead code. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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/x64/full-codegen-x64.cc ('k') | test/mjsunit/harmony/classes-experimental.js » ('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_X87 7 #if V8_TARGET_ARCH_X87
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 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 #endif 408 #endif
409 SetSourcePosition(function()->end_position() - 1); 409 SetSourcePosition(function()->end_position() - 1);
410 __ RecordJSReturn(); 410 __ RecordJSReturn();
411 // Do not use the leave instruction here because it is too short to 411 // Do not use the leave instruction here because it is too short to
412 // patch with the code required by the debugger. 412 // patch with the code required by the debugger.
413 __ mov(esp, ebp); 413 __ mov(esp, ebp);
414 int no_frame_start = masm_->pc_offset(); 414 int no_frame_start = masm_->pc_offset();
415 __ pop(ebp); 415 __ pop(ebp);
416 416
417 int arg_count = info_->scope()->num_parameters() + 1; 417 int arg_count = info_->scope()->num_parameters() + 1;
418 if (FLAG_experimental_classes && 418 if (IsSubclassConstructor(info_->function()->kind())) {
419 IsSubclassConstructor(info_->function()->kind())) {
420 arg_count++; 419 arg_count++;
421 } 420 }
422 int arguments_bytes = arg_count * kPointerSize; 421 int arguments_bytes = arg_count * kPointerSize;
423 __ Ret(arguments_bytes, ecx); 422 __ Ret(arguments_bytes, ecx);
424 // Check that the size of the code used for returning is large enough 423 // Check that the size of the code used for returning is large enough
425 // for the debugger's requirements. 424 // for the debugger's requirements.
426 DCHECK(Assembler::kJSReturnSequenceLength <= 425 DCHECK(Assembler::kJSReturnSequenceLength <=
427 masm_->SizeOfCodeGeneratedSince(&check_exit_codesize)); 426 masm_->SizeOfCodeGeneratedSince(&check_exit_codesize));
428 info_->AddNoFrameRange(no_frame_start, masm_->pc_offset()); 427 info_->AddNoFrameRange(no_frame_start, masm_->pc_offset());
429 } 428 }
(...skipping 2620 matching lines...) Expand 10 before | Expand all | Expand 10 after
3050 PreservePositionScope scope(masm()->positions_recorder()); 3049 PreservePositionScope scope(masm()->positions_recorder());
3051 VisitForStackValue(property->obj()); 3050 VisitForStackValue(property->obj());
3052 } 3051 }
3053 if (is_named_call) { 3052 if (is_named_call) {
3054 EmitCallWithLoadIC(expr); 3053 EmitCallWithLoadIC(expr);
3055 } else { 3054 } else {
3056 EmitKeyedCallWithLoadIC(expr, property->key()); 3055 EmitKeyedCallWithLoadIC(expr, property->key());
3057 } 3056 }
3058 } 3057 }
3059 } else if (call_type == Call::SUPER_CALL) { 3058 } else if (call_type == Call::SUPER_CALL) {
3060 if (FLAG_experimental_classes) { 3059 EmitSuperConstructorCall(expr);
3061 EmitSuperConstructorCall(expr);
3062 } else {
3063 SuperReference* super_ref = callee->AsSuperReference();
3064 EmitLoadSuperConstructor();
3065 __ push(result_register());
3066 VisitForStackValue(super_ref->this_var());
3067 EmitCall(expr, CallICState::METHOD);
3068 }
3069 } else { 3060 } else {
3070 DCHECK(call_type == Call::OTHER_CALL); 3061 DCHECK(call_type == Call::OTHER_CALL);
3071 // Call to an arbitrary expression not handled specially above. 3062 // Call to an arbitrary expression not handled specially above.
3072 { PreservePositionScope scope(masm()->positions_recorder()); 3063 { PreservePositionScope scope(masm()->positions_recorder());
3073 VisitForStackValue(callee); 3064 VisitForStackValue(callee);
3074 } 3065 }
3075 __ push(Immediate(isolate()->factory()->undefined_value())); 3066 __ push(Immediate(isolate()->factory()->undefined_value()));
3076 // Emit function call. 3067 // Emit function call.
3077 EmitCall(expr); 3068 EmitCall(expr);
3078 } 3069 }
(...skipping 2258 matching lines...) Expand 10 before | Expand all | Expand 10 after
5337 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 5328 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
5338 Assembler::target_address_at(call_target_address, 5329 Assembler::target_address_at(call_target_address,
5339 unoptimized_code)); 5330 unoptimized_code));
5340 return OSR_AFTER_STACK_CHECK; 5331 return OSR_AFTER_STACK_CHECK;
5341 } 5332 }
5342 5333
5343 5334
5344 } } // namespace v8::internal 5335 } } // namespace v8::internal
5345 5336
5346 #endif // V8_TARGET_ARCH_X87 5337 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/x64/full-codegen-x64.cc ('k') | test/mjsunit/harmony/classes-experimental.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698