From: ricow@chromium.org Date: Mon, 21 Nov 2011 14:07:46 +0000 (+0000) Subject: Always create deopt data when using full-codegen if the function is optimizable X-Git-Tag: upstream/4.7.83~17872 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ec04dcfa0c80f7938e92e624982508d60c1c50e4;p=platform%2Fupstream%2Fv8.git Always create deopt data when using full-codegen if the function is optimizable Review URL: http://codereview.chromium.org/8611003 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10040 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- diff --git a/src/compiler.cc b/src/compiler.cc index 8b34f02..fc92adf 100644 --- a/src/compiler.cc +++ b/src/compiler.cc @@ -168,7 +168,11 @@ static void FinishOptimization(Handle function, int64_t start) { static bool MakeCrankshaftCode(CompilationInfo* info) { // Test if we can optimize this function when asked to. We can only // do this after the scopes are computed. - if (!info->AllowOptimize()) info->DisableOptimization(); + if (!info->AllowOptimize()) { + info->DisableOptimization(); + } else if (info->IsOptimizable()) { + info->EnableDeoptimizationSupport(); + } // In case we are not optimizing simply return the code from // the full code generator.