Index: src/arm/lithium-codegen-arm.cc |
diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc |
index 8c9221cc4a60efaea356afea7df79cb34589b29c..7f5900df0e5b6de3c3071b2416dd67a77597eea0 100644 |
--- a/src/arm/lithium-codegen-arm.cc |
+++ b/src/arm/lithium-codegen-arm.cc |
@@ -908,6 +908,13 @@ void LCodeGen::PopulateDeoptimizationData(Handle<Code> code) { |
data->SetTranslationByteArray(*translations); |
data->SetInlinedFunctionCount(Smi::FromInt(inlined_function_count_)); |
data->SetOptimizationId(Smi::FromInt(info_->optimization_id())); |
+ if (info_->IsOptimizing()) { |
+ // Reference to shared function info does not change between phases. |
+ AllowDeferredHandleDereference allow_handle_dereference; |
+ data->SetSharedFunctionInfo(*info_->shared_info()); |
+ } else { |
+ data->SetSharedFunctionInfo(Smi::FromInt(0)); |
+ } |
Handle<FixedArray> literals = |
factory()->NewFixedArray(deoptimization_literals_.length(), TENURED); |