| Index: src/runtime-profiler.h
|
| diff --git a/src/runtime-profiler.h b/src/runtime-profiler.h
|
| index 15c209713e93b42aa34ed24539865092afbe66d4..4aebee6e7484cbf0f1c529720fe9dbf26e3e4743 100644
|
| --- a/src/runtime-profiler.h
|
| +++ b/src/runtime-profiler.h
|
| @@ -58,8 +58,13 @@ class RuntimeProfiler {
|
| void Reset();
|
| void TearDown();
|
|
|
| - Object** SamplerWindowAddress();
|
| - int SamplerWindowSize();
|
| + void NotifyICChanged() {
|
| + any_ic_changed_ = true;
|
| + }
|
| + void NotifyCodeGenerated(int generated_code_size) {
|
| + code_generated_ = true;
|
| + total_code_generated_ += generated_code_size;
|
| + }
|
|
|
| // Rate limiting support.
|
|
|
| @@ -88,16 +93,10 @@ class RuntimeProfiler {
|
| // turned off.
|
| static void StopRuntimeProfilerThreadBeforeShutdown(Thread* thread);
|
|
|
| - void UpdateSamplesAfterScavenge();
|
| - void RemoveDeadSamples();
|
| - void UpdateSamplesAfterCompact(ObjectVisitor* visitor);
|
| -
|
| private:
|
| - static const int kSamplerWindowSize = 16;
|
| -
|
| static void HandleWakeUp(Isolate* isolate);
|
|
|
| - void Optimize(JSFunction* function);
|
| + void Optimize(JSFunction* function, int reason);
|
|
|
| void AttemptOnStackReplacement(JSFunction* function);
|
|
|
| @@ -105,19 +104,11 @@ class RuntimeProfiler {
|
|
|
| void ClearSampleBufferNewSpaceEntries();
|
|
|
| - int LookupSample(JSFunction* function);
|
| -
|
| - void AddSample(JSFunction* function, int weight);
|
| -
|
| Isolate* isolate_;
|
|
|
| - int sampler_threshold_;
|
| - int sampler_threshold_size_factor_;
|
| - int sampler_ticks_until_threshold_adjustment_;
|
| -
|
| - Object* sampler_window_[kSamplerWindowSize];
|
| - int sampler_window_position_;
|
| - int sampler_window_weight_[kSamplerWindowSize];
|
| + bool any_ic_changed_;
|
| + bool code_generated_;
|
| + int total_code_generated_;
|
|
|
| // Possible state values:
|
| // -1 => the profiler thread is waiting on the semaphore
|
|
|