Index: src/hydrogen.cc |
diff --git a/src/hydrogen.cc b/src/hydrogen.cc |
index 097216ef830b9660042ee31ee2bb82a618ca5e23..4cf86136bdce2d612d254b1e8b57b234c76e57de 100644 |
--- a/src/hydrogen.cc |
+++ b/src/hydrogen.cc |
@@ -11012,9 +11012,11 @@ void HOptimizedGraphBuilder::BuildEmitDeepCopy( |
AddInstruction(new(zone) HConstant(i, Representation::Integer32())); |
HInstruction* value_instruction = |
AddInstruction(new(zone) HLoadKeyed( |
- boilerplate_elements, key_constant, NULL, kind)); |
- AddInstruction(new(zone) HStoreKeyed( |
+ boilerplate_elements, key_constant, NULL, kind, |
+ ALLOW_RETURN_HOLE)); |
+ HInstruction* store = AddInstruction(new(zone) HStoreKeyed( |
object_elements, key_constant, value_instruction, kind)); |
+ store->ClearFlag(HValue::kDeoptimizeOnUndefined); |
} |
} else if (elements->IsFixedArray()) { |
Handle<FixedArray> fast_elements = Handle<FixedArray>::cast(elements); |
@@ -11037,7 +11039,8 @@ void HOptimizedGraphBuilder::BuildEmitDeepCopy( |
} else { |
HInstruction* value_instruction = |
AddInstruction(new(zone) HLoadKeyed( |
- boilerplate_elements, key_constant, NULL, kind)); |
+ boilerplate_elements, key_constant, NULL, kind, |
+ ALLOW_RETURN_HOLE)); |
AddInstruction(new(zone) HStoreKeyed( |
object_elements, key_constant, value_instruction, kind)); |
} |