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

Side by Side Diff: src/compiler/ast-graph-builder.cc

Issue 2676583002: [ic] Encode [Keyed]StoreIC's language mode in slot kind instead of code object's flags. (Closed)
Patch Set: Rebasing Created 3 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
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/compiler/ast-graph-builder.h" 5 #include "src/compiler/ast-graph-builder.h"
6 6
7 #include "src/ast/compile-time-value.h" 7 #include "src/ast/compile-time-value.h"
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 #include "src/compilation-info.h" 9 #include "src/compilation-info.h"
10 #include "src/compiler.h" 10 #include "src/compiler.h"
(...skipping 2727 matching lines...) Expand 10 before | Expand all | Expand 10 after
2738 Node* AstGraphBuilder::BuildNamedLoad(Node* object, Handle<Name> name, 2738 Node* AstGraphBuilder::BuildNamedLoad(Node* object, Handle<Name> name,
2739 const VectorSlotPair& feedback) { 2739 const VectorSlotPair& feedback) {
2740 const Operator* op = javascript()->LoadNamed(name, feedback); 2740 const Operator* op = javascript()->LoadNamed(name, feedback);
2741 Node* node = NewNode(op, object); 2741 Node* node = NewNode(op, object);
2742 return node; 2742 return node;
2743 } 2743 }
2744 2744
2745 2745
2746 Node* AstGraphBuilder::BuildKeyedStore(Node* object, Node* key, Node* value, 2746 Node* AstGraphBuilder::BuildKeyedStore(Node* object, Node* key, Node* value,
2747 const VectorSlotPair& feedback) { 2747 const VectorSlotPair& feedback) {
2748 DCHECK_EQ(feedback.vector()->GetLanguageMode(feedback.slot()),
2749 language_mode());
2748 const Operator* op = javascript()->StoreProperty(language_mode(), feedback); 2750 const Operator* op = javascript()->StoreProperty(language_mode(), feedback);
2749 Node* node = NewNode(op, object, key, value); 2751 Node* node = NewNode(op, object, key, value);
2750 return node; 2752 return node;
2751 } 2753 }
2752 2754
2753 2755
2754 Node* AstGraphBuilder::BuildNamedStore(Node* object, Handle<Name> name, 2756 Node* AstGraphBuilder::BuildNamedStore(Node* object, Handle<Name> name,
2755 Node* value, 2757 Node* value,
2756 const VectorSlotPair& feedback) { 2758 const VectorSlotPair& feedback) {
2759 DCHECK_EQ(feedback.vector()->GetLanguageMode(feedback.slot()),
2760 language_mode());
2757 const Operator* op = 2761 const Operator* op =
2758 javascript()->StoreNamed(language_mode(), name, feedback); 2762 javascript()->StoreNamed(language_mode(), name, feedback);
2759 Node* node = NewNode(op, object, value); 2763 Node* node = NewNode(op, object, value);
2760 return node; 2764 return node;
2761 } 2765 }
2762 2766
2763 2767
2764 Node* AstGraphBuilder::BuildGlobalLoad(Handle<Name> name, 2768 Node* AstGraphBuilder::BuildGlobalLoad(Handle<Name> name,
2765 const VectorSlotPair& feedback, 2769 const VectorSlotPair& feedback,
2766 TypeofMode typeof_mode) { 2770 TypeofMode typeof_mode) {
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
3309 float invocation_frequency, LoopAssignmentAnalysis* loop_assignment, 3313 float invocation_frequency, LoopAssignmentAnalysis* loop_assignment,
3310 SourcePositionTable* source_positions, int inlining_id) 3314 SourcePositionTable* source_positions, int inlining_id)
3311 : AstGraphBuilder(local_zone, info, jsgraph, invocation_frequency, 3315 : AstGraphBuilder(local_zone, info, jsgraph, invocation_frequency,
3312 loop_assignment), 3316 loop_assignment),
3313 source_positions_(source_positions), 3317 source_positions_(source_positions),
3314 start_position_(info->shared_info()->start_position(), inlining_id) {} 3318 start_position_(info->shared_info()->start_position(), inlining_id) {}
3315 3319
3316 } // namespace compiler 3320 } // namespace compiler
3317 } // namespace internal 3321 } // namespace internal
3318 } // namespace v8 3322 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698