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/interpreter/interpreter-generator.cc

Issue 2755973002: [type profile] Collect return types. (Closed)
Patch Set: Rebase. Created 3 years, 9 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/interpreter/bytecodes.h ('k') | src/runtime/runtime-object.cc » ('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 2017 the V8 project authors. All rights reserved. 1 // Copyright 2017 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/interpreter/interpreter-generator.h" 5 #include "src/interpreter/interpreter-generator.h"
6 6
7 #include <array> 7 #include <array>
8 #include <tuple> 8 #include <tuple>
9 9
10 #include "src/builtins/builtins-arguments.h" 10 #include "src/builtins/builtins-arguments.h"
(...skipping 804 matching lines...) Expand 10 before | Expand all | Expand 10 after
815 Node* feedback_vector = __ LoadFeedbackVector(); 815 Node* feedback_vector = __ LoadFeedbackVector();
816 Node* context = __ GetContext(); 816 Node* context = __ GetContext();
817 817
818 __ CallRuntime(Runtime::kDefineDataPropertyInLiteral, context, object, name, 818 __ CallRuntime(Runtime::kDefineDataPropertyInLiteral, context, object, name,
819 value, flags, feedback_vector, vector_index); 819 value, flags, feedback_vector, vector_index);
820 __ Dispatch(); 820 __ Dispatch();
821 } 821 }
822 822
823 void InterpreterGenerator::DoCollectTypeProfile( 823 void InterpreterGenerator::DoCollectTypeProfile(
824 InterpreterAssembler* assembler) { 824 InterpreterAssembler* assembler) {
825 Node* name = __ LoadRegister(__ BytecodeOperandReg(0)); 825 Node* position = __ BytecodeOperandImmSmi(0);
826 Node* value = __ GetAccumulator(); 826 Node* value = __ GetAccumulator();
827 Node* vector_index = __ SmiTag(__ BytecodeOperandIdx(1)); 827 Node* vector_index = __ SmiTag(__ BytecodeOperandIdx(1));
828 828
829 Node* feedback_vector = __ LoadFeedbackVector(); 829 Node* feedback_vector = __ LoadFeedbackVector();
830 Node* context = __ GetContext(); 830 Node* context = __ GetContext();
831 831
832 __ CallRuntime(Runtime::kCollectTypeProfile, context, name, value, 832 __ CallRuntime(Runtime::kCollectTypeProfile, context, position, value,
833 feedback_vector, vector_index); 833 feedback_vector, vector_index);
834 __ Dispatch(); 834 __ Dispatch();
835 } 835 }
836 836
837 // LdaModuleVariable <cell_index> <depth> 837 // LdaModuleVariable <cell_index> <depth>
838 // 838 //
839 // Load the contents of a module variable into the accumulator. The variable is 839 // Load the contents of a module variable into the accumulator. The variable is
840 // identified by <cell_index>. <depth> is the depth of the current context 840 // identified by <cell_index>. <depth> is the depth of the current context
841 // relative to the module context. 841 // relative to the module context.
842 void InterpreterGenerator::DoLdaModuleVariable( 842 void InterpreterGenerator::DoLdaModuleVariable(
(...skipping 2578 matching lines...) Expand 10 before | Expand all | Expand 10 after
3421 __ StoreObjectField(generator, JSGeneratorObject::kContinuationOffset, 3421 __ StoreObjectField(generator, JSGeneratorObject::kContinuationOffset,
3422 __ SmiTag(new_state)); 3422 __ SmiTag(new_state));
3423 __ SetAccumulator(old_state); 3423 __ SetAccumulator(old_state);
3424 3424
3425 __ Dispatch(); 3425 __ Dispatch();
3426 } 3426 }
3427 3427
3428 } // namespace interpreter 3428 } // namespace interpreter
3429 } // namespace internal 3429 } // namespace internal
3430 } // namespace v8 3430 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/bytecodes.h ('k') | src/runtime/runtime-object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698