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

Side by Side Diff: src/interpreter/bytecode-generator.cc

Issue 2096653003: [ic] Don't pass receiver and name to LoadGlobalIC. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@store-name-in-metavector
Patch Set: Removed name parameter. Created 4 years, 5 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/bytecode-array-builder.cc ('k') | src/interpreter/bytecodes.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/bytecode-generator.h" 5 #include "src/interpreter/bytecode-generator.h"
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/compiler.h" 9 #include "src/compiler.h"
10 #include "src/interpreter/bytecode-register-allocator.h" 10 #include "src/interpreter/bytecode-register-allocator.h"
(...skipping 1779 matching lines...) Expand 10 before | Expand all | Expand 10 after
1790 // The parameter indices are shifted by 1 (receiver is variable 1790 // The parameter indices are shifted by 1 (receiver is variable
1791 // index -1 but is parameter index 0 in BytecodeArrayBuilder). 1791 // index -1 but is parameter index 0 in BytecodeArrayBuilder).
1792 Register source = builder()->Parameter(variable->index() + 1); 1792 Register source = builder()->Parameter(variable->index() + 1);
1793 builder()->LoadAccumulatorWithRegister(source); 1793 builder()->LoadAccumulatorWithRegister(source);
1794 BuildHoleCheckForVariableLoad(mode, variable->name()); 1794 BuildHoleCheckForVariableLoad(mode, variable->name());
1795 execution_result()->SetResultInAccumulator(); 1795 execution_result()->SetResultInAccumulator();
1796 break; 1796 break;
1797 } 1797 }
1798 case VariableLocation::GLOBAL: 1798 case VariableLocation::GLOBAL:
1799 case VariableLocation::UNALLOCATED: { 1799 case VariableLocation::UNALLOCATED: {
1800 builder()->LoadGlobal(variable->name(), feedback_index(slot), 1800 builder()->LoadGlobal(feedback_index(slot), typeof_mode);
1801 typeof_mode);
1802 execution_result()->SetResultInAccumulator(); 1801 execution_result()->SetResultInAccumulator();
1803 break; 1802 break;
1804 } 1803 }
1805 case VariableLocation::CONTEXT: { 1804 case VariableLocation::CONTEXT: {
1806 int depth = execution_context()->ContextChainDepth(variable->scope()); 1805 int depth = execution_context()->ContextChainDepth(variable->scope());
1807 ContextScope* context = execution_context()->Previous(depth); 1806 ContextScope* context = execution_context()->Previous(depth);
1808 Register context_reg; 1807 Register context_reg;
1809 if (context) { 1808 if (context) {
1810 context_reg = context->reg(); 1809 context_reg = context->reg();
1811 } else { 1810 } else {
(...skipping 1367 matching lines...) Expand 10 before | Expand all | Expand 10 after
3179 return execution_context()->scope()->language_mode(); 3178 return execution_context()->scope()->language_mode();
3180 } 3179 }
3181 3180
3182 int BytecodeGenerator::feedback_index(FeedbackVectorSlot slot) const { 3181 int BytecodeGenerator::feedback_index(FeedbackVectorSlot slot) const {
3183 return TypeFeedbackVector::GetIndex(slot); 3182 return TypeFeedbackVector::GetIndex(slot);
3184 } 3183 }
3185 3184
3186 } // namespace interpreter 3185 } // namespace interpreter
3187 } // namespace internal 3186 } // namespace internal
3188 } // namespace v8 3187 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/bytecode-array-builder.cc ('k') | src/interpreter/bytecodes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698