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

Side by Side Diff: src/crankshaft/hydrogen.cc

Issue 1448933002: Introduce a BuiltinsConstructStub that sets up new.target and does a [[call]] per ES6 9.3.2 (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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/contexts.h ('k') | src/execution.h » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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/crankshaft/hydrogen.h" 5 #include "src/crankshaft/hydrogen.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/allocation-site-scopes.h" 9 #include "src/allocation-site-scopes.h"
10 #include "src/ast-numbering.h" 10 #include "src/ast-numbering.h"
(...skipping 9908 matching lines...) Expand 10 before | Expand all | Expand 10 after
9919 if (function->IsConstant() && 9919 if (function->IsConstant() &&
9920 HConstant::cast(function)->handle(isolate())->IsJSFunction()) { 9920 HConstant::cast(function)->handle(isolate())->IsJSFunction()) {
9921 Handle<Object> constant = HConstant::cast(function)->handle(isolate()); 9921 Handle<Object> constant = HConstant::cast(function)->handle(isolate());
9922 expr->SetKnownGlobalTarget(Handle<JSFunction>::cast(constant)); 9922 expr->SetKnownGlobalTarget(Handle<JSFunction>::cast(constant));
9923 } 9923 }
9924 9924
9925 if (FLAG_inline_construct && 9925 if (FLAG_inline_construct &&
9926 expr->IsMonomorphic() && 9926 expr->IsMonomorphic() &&
9927 IsAllocationInlineable(expr->target())) { 9927 IsAllocationInlineable(expr->target())) {
9928 Handle<JSFunction> constructor = expr->target(); 9928 Handle<JSFunction> constructor = expr->target();
9929 DCHECK(
9930 constructor->shared()->construct_stub() ==
9931 isolate()->builtins()->builtin(Builtins::kJSConstructStubGeneric) ||
9932 constructor->shared()->construct_stub() ==
9933 isolate()->builtins()->builtin(Builtins::kJSConstructStubApi));
9929 HValue* check = Add<HCheckValue>(function, constructor); 9934 HValue* check = Add<HCheckValue>(function, constructor);
9930 9935
9931 // Force completion of inobject slack tracking before generating 9936 // Force completion of inobject slack tracking before generating
9932 // allocation code to finalize instance size. 9937 // allocation code to finalize instance size.
9933 if (constructor->IsInobjectSlackTrackingInProgress()) { 9938 if (constructor->IsInobjectSlackTrackingInProgress()) {
9934 constructor->CompleteInobjectSlackTracking(); 9939 constructor->CompleteInobjectSlackTracking();
9935 } 9940 }
9936 9941
9937 // Calculate instance size from initial map of constructor. 9942 // Calculate instance size from initial map of constructor.
9938 DCHECK(constructor->has_initial_map()); 9943 DCHECK(constructor->has_initial_map());
(...skipping 3691 matching lines...) Expand 10 before | Expand all | Expand 10 after
13630 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 13635 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
13631 } 13636 }
13632 13637
13633 #ifdef DEBUG 13638 #ifdef DEBUG
13634 graph_->Verify(false); // No full verify. 13639 graph_->Verify(false); // No full verify.
13635 #endif 13640 #endif
13636 } 13641 }
13637 13642
13638 } // namespace internal 13643 } // namespace internal
13639 } // namespace v8 13644 } // namespace v8
OLDNEW
« no previous file with comments | « src/contexts.h ('k') | src/execution.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698