Index: src/lithium.cc |
diff --git a/src/lithium.cc b/src/lithium.cc |
index 81944b2c54f3ada96c3e340b0b717f7f1d09efc1..108eb7f777fe2720853c8a121e3fd1bb67dc2962 100644 |
--- a/src/lithium.cc |
+++ b/src/lithium.cc |
@@ -429,7 +429,9 @@ Handle<Code> LChunk::Codegen(Code::Kind kind) { |
Handle<Code> code = |
CodeGenerator::MakeCodeEpilogue(&assembler, flags, info()); |
generator.FinishCode(code); |
- RegisterDependentCodeForEmbeddedMaps(code); |
+ if (FLAG_weak_embedded_maps_in_optimized_code) { |
+ RegisterDependentCodeForEmbeddedMaps(code); |
+ } |
CodeGenerator::PrintCode(code, info()); |
return code; |
} |