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

Side by Side Diff: src/compiler/js-operator.cc

Issue 2435023002: Use a different map to distinguish eval contexts (Closed)
Patch Set: Crankshaft backends and scope deserialization Created 4 years, 2 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/js-operator.h" 5 #include "src/compiler/js-operator.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "src/base/lazy-instance.h" 9 #include "src/base/lazy-instance.h"
10 #include "src/compiler/opcodes.h" 10 #include "src/compiler/opcodes.h"
(...skipping 825 matching lines...) Expand 10 before | Expand all | Expand 10 after
836 836
837 837
838 const Operator* JSOperatorBuilder::CreateFunctionContext(int slot_count) { 838 const Operator* JSOperatorBuilder::CreateFunctionContext(int slot_count) {
839 return new (zone()) Operator1<int>( // -- 839 return new (zone()) Operator1<int>( // --
840 IrOpcode::kJSCreateFunctionContext, Operator::kNoProperties, // opcode 840 IrOpcode::kJSCreateFunctionContext, Operator::kNoProperties, // opcode
841 "JSCreateFunctionContext", // name 841 "JSCreateFunctionContext", // name
842 1, 1, 1, 1, 1, 2, // counts 842 1, 1, 1, 1, 1, 2, // counts
843 slot_count); // parameter 843 slot_count); // parameter
844 } 844 }
845 845
846 const Operator* JSOperatorBuilder::CreateEvalContext(int slot_count) {
847 return new (zone()) Operator1<int>( // --
848 IrOpcode::kJSCreateEvalContext, Operator::kNoProperties, // opcode
849 "JSCreateEvalContext", // name
850 1, 1, 1, 1, 1, 2, // counts
851 slot_count); // parameter
852 }
853
846 const Operator* JSOperatorBuilder::CreateCatchContext( 854 const Operator* JSOperatorBuilder::CreateCatchContext(
847 const Handle<String>& name, const Handle<ScopeInfo>& scope_info) { 855 const Handle<String>& name, const Handle<ScopeInfo>& scope_info) {
848 CreateCatchContextParameters parameters(name, scope_info); 856 CreateCatchContextParameters parameters(name, scope_info);
849 return new (zone()) Operator1<CreateCatchContextParameters>( 857 return new (zone()) Operator1<CreateCatchContextParameters>(
850 IrOpcode::kJSCreateCatchContext, Operator::kNoProperties, // opcode 858 IrOpcode::kJSCreateCatchContext, Operator::kNoProperties, // opcode
851 "JSCreateCatchContext", // name 859 "JSCreateCatchContext", // name
852 2, 1, 1, 1, 1, 2, // counts 860 2, 1, 1, 1, 1, 2, // counts
853 parameters); // parameter 861 parameters); // parameter
854 } 862 }
855 863
(...skipping 21 matching lines...) Expand all
877 return new (zone()) Operator1<Handle<ScopeInfo>>( // -- 885 return new (zone()) Operator1<Handle<ScopeInfo>>( // --
878 IrOpcode::kJSCreateScriptContext, Operator::kNoProperties, // opcode 886 IrOpcode::kJSCreateScriptContext, Operator::kNoProperties, // opcode
879 "JSCreateScriptContext", // name 887 "JSCreateScriptContext", // name
880 1, 1, 1, 1, 1, 2, // counts 888 1, 1, 1, 1, 1, 2, // counts
881 scpope_info); // parameter 889 scpope_info); // parameter
882 } 890 }
883 891
884 } // namespace compiler 892 } // namespace compiler
885 } // namespace internal 893 } // namespace internal
886 } // namespace v8 894 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-operator.h ('k') | src/compiler/opcodes.h » ('j') | src/contexts.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698