Profiler experiments: remove "stable on startup" rule

Review URL: https://chromiumcodereview.appspot.com/9864030

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11164 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 6306283d
...@@ -330,9 +330,6 @@ bool FullCodeGenerator::MakeCode(CompilationInfo* info) { ...@@ -330,9 +330,6 @@ bool FullCodeGenerator::MakeCode(CompilationInfo* info) {
code->set_stack_check_table_offset(table_offset); code->set_stack_check_table_offset(table_offset);
CodeGenerator::PrintCode(code, info); CodeGenerator::PrintCode(code, info);
info->SetCode(code); // May be an empty handle. info->SetCode(code); // May be an empty handle.
if (!code.is_null()) {
isolate->runtime_profiler()->NotifyCodeGenerated(code->instruction_size());
}
#ifdef ENABLE_GDB_JIT_INTERFACE #ifdef ENABLE_GDB_JIT_INTERFACE
if (FLAG_gdbjit && !code.is_null()) { if (FLAG_gdbjit && !code.is_null()) {
GDBJITLineInfo* lineinfo = GDBJITLineInfo* lineinfo =
......
...@@ -313,14 +313,6 @@ void RuntimeProfiler::OptimizeNow() { ...@@ -313,14 +313,6 @@ void RuntimeProfiler::OptimizeNow() {
// If no IC was patched since the last tick and this function is very // If no IC was patched since the last tick and this function is very
// small, optimistically optimize it now. // small, optimistically optimize it now.
Optimize(function, "small function"); Optimize(function, "small function");
} else if (!code_generated_ &&
!any_ic_changed_ &&
total_code_generated_ > 0 &&
total_code_generated_ < 2000) {
// If no code was generated and no IC was patched since the last tick,
// but a little code has already been generated since last Reset(),
// then type info might already be stable and we can optimize now.
Optimize(function, "stable on startup");
} else { } else {
shared_code->set_profiler_ticks(ticks + 1); shared_code->set_profiler_ticks(ticks + 1);
} }
...@@ -341,7 +333,6 @@ void RuntimeProfiler::OptimizeNow() { ...@@ -341,7 +333,6 @@ void RuntimeProfiler::OptimizeNow() {
} }
if (FLAG_watch_ic_patching) { if (FLAG_watch_ic_patching) {
any_ic_changed_ = false; any_ic_changed_ = false;
code_generated_ = false;
} else { // !FLAG_watch_ic_patching } else { // !FLAG_watch_ic_patching
// Add the collected functions as samples. It's important not to do // Add the collected functions as samples. It's important not to do
// this as part of collecting them because this will interfere with // this as part of collecting them because this will interfere with
...@@ -371,9 +362,7 @@ void RuntimeProfiler::SetUp() { ...@@ -371,9 +362,7 @@ void RuntimeProfiler::SetUp() {
void RuntimeProfiler::Reset() { void RuntimeProfiler::Reset() {
if (FLAG_watch_ic_patching) { if (!FLAG_watch_ic_patching) {
total_code_generated_ = 0;
} else { // !FLAG_watch_ic_patching
sampler_threshold_ = kSamplerThresholdInit; sampler_threshold_ = kSamplerThresholdInit;
sampler_threshold_size_factor_ = kSamplerThresholdSizeFactorInit; sampler_threshold_size_factor_ = kSamplerThresholdSizeFactorInit;
sampler_ticks_until_threshold_adjustment_ = sampler_ticks_until_threshold_adjustment_ =
......
...@@ -63,13 +63,6 @@ class RuntimeProfiler { ...@@ -63,13 +63,6 @@ class RuntimeProfiler {
void NotifyICChanged() { any_ic_changed_ = true; } void NotifyICChanged() { any_ic_changed_ = true; }
void NotifyCodeGenerated(int generated_code_size) {
if (FLAG_watch_ic_patching) {
code_generated_ = true;
total_code_generated_ += generated_code_size;
}
}
// Rate limiting support. // Rate limiting support.
// VM thread interface. // VM thread interface.
...@@ -130,7 +123,6 @@ class RuntimeProfiler { ...@@ -130,7 +123,6 @@ class RuntimeProfiler {
bool any_ic_changed_; bool any_ic_changed_;
bool code_generated_; bool code_generated_;
int total_code_generated_;
// Possible state values: // Possible state values:
// -1 => the profiler thread is waiting on the semaphore // -1 => the profiler thread is waiting on the semaphore
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment