Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: src/runtime-profiler.cc

Issue 755173002: Partially revert "Optimize function across closures." (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/objects-inl.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/runtime-profiler.h" 7 #include "src/runtime-profiler.h"
8 8
9 #include "src/assembler.h" 9 #include "src/assembler.h"
10 #include "src/base/platform/platform.h" 10 #include "src/base/platform/platform.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 int typeinfo, generic, total, type_percentage, generic_percentage; 99 int typeinfo, generic, total, type_percentage, generic_percentage;
100 GetICCounts(function->shared(), &typeinfo, &generic, &total, 100 GetICCounts(function->shared(), &typeinfo, &generic, &total,
101 &type_percentage, &generic_percentage); 101 &type_percentage, &generic_percentage);
102 PrintF(", ICs with typeinfo: %d/%d (%d%%)", typeinfo, total, 102 PrintF(", ICs with typeinfo: %d/%d (%d%%)", typeinfo, total,
103 type_percentage); 103 type_percentage);
104 PrintF(", generic ICs: %d/%d (%d%%)", generic, total, generic_percentage); 104 PrintF(", generic ICs: %d/%d (%d%%)", generic, total, generic_percentage);
105 } 105 }
106 PrintF("]\n"); 106 PrintF("]\n");
107 } 107 }
108 108
109 function->shared()->set_optimize_next_closure(true);
110 function->AttemptConcurrentOptimization(); 109 function->AttemptConcurrentOptimization();
111 } 110 }
112 111
113 112
114 void RuntimeProfiler::AttemptOnStackReplacement(JSFunction* function, 113 void RuntimeProfiler::AttemptOnStackReplacement(JSFunction* function,
115 int loop_nesting_levels) { 114 int loop_nesting_levels) {
116 SharedFunctionInfo* shared = function->shared(); 115 SharedFunctionInfo* shared = function->shared();
117 // See AlwaysFullCompiler (in compiler.cc) comment on why we need 116 // See AlwaysFullCompiler (in compiler.cc) comment on why we need
118 // Debug::has_break_points(). 117 // Debug::has_break_points().
119 if (!FLAG_use_osr || 118 if (!FLAG_use_osr ||
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 } 261 }
263 } else { 262 } else {
264 shared_code->set_profiler_ticks(ticks + 1); 263 shared_code->set_profiler_ticks(ticks + 1);
265 } 264 }
266 } 265 }
267 any_ic_changed_ = false; 266 any_ic_changed_ = false;
268 } 267 }
269 268
270 269
271 } } // namespace v8::internal 270 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/objects-inl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698