Index: src/interpreter/bytecode-array-builder.cc |
diff --git a/src/interpreter/bytecode-array-builder.cc b/src/interpreter/bytecode-array-builder.cc |
index 5976c6686e51bd92459a8968befa8c2818ceafee..8c9896e5f43c33ed638e6fc99495bf411dad3d70 100644 |
--- a/src/interpreter/bytecode-array-builder.cc |
+++ b/src/interpreter/bytecode-array-builder.cc |
@@ -6,6 +6,7 @@ |
#include "src/compiler.h" |
#include "src/interpreter/bytecode-array-writer.h" |
+#include "src/interpreter/bytecode-dead-code-optimizer.h" |
#include "src/interpreter/bytecode-label.h" |
#include "src/interpreter/bytecode-peephole-optimizer.h" |
#include "src/interpreter/bytecode-register-optimizer.h" |
@@ -35,6 +36,10 @@ BytecodeArrayBuilder::BytecodeArrayBuilder(Isolate* isolate, Zone* zone, |
DCHECK_GE(context_register_count_, 0); |
DCHECK_GE(local_register_count_, 0); |
+ if (FLAG_ignition_deadcode) { |
+ pipeline_ = new (zone) BytecodeDeadCodeOptimizer(pipeline_); |
+ } |
+ |
if (FLAG_ignition_peephole) { |
pipeline_ = new (zone) |
BytecodePeepholeOptimizer(&constant_array_builder_, pipeline_); |