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

Unified Diff: src/compiler/ast-graph-builder.cc

Issue 1466643002: [turbofan] Initial support for Array constructor specialization. (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/compiler/js-call-reducer.h » ('j') | src/compiler/js-operator.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ast-graph-builder.cc
diff --git a/src/compiler/ast-graph-builder.cc b/src/compiler/ast-graph-builder.cc
index 4b9c97c5d526e3149cca91c50c10cbf58b27e30a..f9a183ea1f7684686eb4d01d0d3ccfe07a686e9d 100644
--- a/src/compiler/ast-graph-builder.cc
+++ b/src/compiler/ast-graph-builder.cc
@@ -2530,7 +2530,9 @@ void AstGraphBuilder::VisitCallNew(CallNew* expr) {
environment()->Push(environment()->Peek(args->length()));
// Create node to perform the construct call.
- const Operator* call = javascript()->CallConstruct(args->length() + 2);
+ VectorSlotPair feedback = CreateVectorSlotPair(expr->CallNewFeedbackSlot());
+ const Operator* call =
+ javascript()->CallConstruct(args->length() + 2, feedback);
Node* value = ProcessArguments(call, args->length() + 2);
PrepareFrameState(value, expr->id(), ast_context()->GetStateCombine());
ast_context()->ProduceValue(value);
@@ -3652,8 +3654,7 @@ Node* AstGraphBuilder::BuildLoadGlobalObject() {
Node* AstGraphBuilder::BuildLoadNativeContextField(int index) {
Node* global = BuildLoadGlobalObject();
- Node* native_context =
- BuildLoadObjectField(global, JSGlobalObject::kNativeContextOffset);
+ Node* native_context = NewNode(javascript()->LoadNativeContext(), global);
return NewNode(javascript()->LoadContext(0, index, true), native_context);
}
« no previous file with comments | « no previous file | src/compiler/js-call-reducer.h » ('j') | src/compiler/js-operator.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698