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
3 // found in the LICENSE file.
5 #ifndef V8_RUNTIME_PROFILER_H_
6 #define V8_RUNTIME_PROFILER_H_
8 #include "src/allocation.h"
22 class RuntimeProfiler {
24 explicit RuntimeProfiler(Isolate* isolate);
28 void NotifyICChanged() { any_ic_changed_ = true; }
30 void AttemptOnStackReplacement(JSFunction* function, int nesting_levels = 1);
33 void Optimize(JSFunction* function, const char* reason);
35 bool CodeSizeOKForOSR(Code* shared_code);
42 } // namespace internal
45 #endif // V8_RUNTIME_PROFILER_H_