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

Side by Side Diff: src/interpreter/bytecode-peephole-optimizer.cc

Issue 2242193002: [Interpreter] Avoid accessing Isolate from during bytecode generation. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@offheap_sourceposition
Patch Set: Rebase Created 4 years, 4 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-peephole-optimizer.h ('k') | src/interpreter/bytecode-pipeline.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 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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-peephole-optimizer.h" 5 #include "src/interpreter/bytecode-peephole-optimizer.h"
6 6
7 #include "src/objects-inl.h" 7 #include "src/objects-inl.h"
8 #include "src/objects.h" 8 #include "src/objects.h"
9 9
10 namespace v8 { 10 namespace v8 {
11 namespace internal { 11 namespace internal {
12 namespace interpreter { 12 namespace interpreter {
13 13
14 BytecodePeepholeOptimizer::BytecodePeepholeOptimizer( 14 BytecodePeepholeOptimizer::BytecodePeepholeOptimizer(
15 BytecodePipelineStage* next_stage) 15 BytecodePipelineStage* next_stage)
16 : next_stage_(next_stage) { 16 : next_stage_(next_stage) {
17 InvalidateLast(); 17 InvalidateLast();
18 } 18 }
19 19
20 // override 20 // override
21 Handle<BytecodeArray> BytecodePeepholeOptimizer::ToBytecodeArray( 21 Handle<BytecodeArray> BytecodePeepholeOptimizer::ToBytecodeArray(
22 int fixed_register_count, int parameter_count, 22 Isolate* isolate, int fixed_register_count, int parameter_count,
23 Handle<FixedArray> handler_table) { 23 Handle<FixedArray> handler_table) {
24 Flush(); 24 Flush();
25 return next_stage_->ToBytecodeArray(fixed_register_count, parameter_count, 25 return next_stage_->ToBytecodeArray(isolate, fixed_register_count,
26 handler_table); 26 parameter_count, handler_table);
27 } 27 }
28 28
29 // override 29 // override
30 void BytecodePeepholeOptimizer::BindLabel(BytecodeLabel* label) { 30 void BytecodePeepholeOptimizer::BindLabel(BytecodeLabel* label) {
31 Flush(); 31 Flush();
32 next_stage_->BindLabel(label); 32 next_stage_->BindLabel(label);
33 } 33 }
34 34
35 // override 35 // override
36 void BytecodePeepholeOptimizer::BindLabel(const BytecodeLabel& target, 36 void BytecodePeepholeOptimizer::BindLabel(const BytecodeLabel& target,
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 #undef CASE 334 #undef CASE
335 default: 335 default:
336 UNREACHABLE(); 336 UNREACHABLE();
337 break; 337 break;
338 } 338 }
339 } 339 }
340 340
341 } // namespace interpreter 341 } // namespace interpreter
342 } // namespace internal 342 } // namespace internal
343 } // namespace v8 343 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/bytecode-peephole-optimizer.h ('k') | src/interpreter/bytecode-pipeline.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698