Changeset 154837 in webkit for trunk/Source/JavaScriptCore/bytecode/CodeBlock.cpp
- Timestamp:
- Aug 29, 2013, 1:27:15 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/bytecode/CodeBlock.cpp
r154833 r154837 2963 2963 } 2964 2964 2965 int32_t CodeBlock:: counterValueForOptimizeAfterWarmUp()2965 int32_t CodeBlock::adjustedCounterValue(int32_t desiredThreshold) 2966 2966 { 2967 2967 return clipThreshold( 2968 Options::thresholdForOptimizeAfterWarmUp() * 2969 optimizationThresholdScalingFactor() * 2970 (1 << reoptimizationRetryCounter())); 2971 } 2972 2973 int32_t CodeBlock::counterValueForOptimizeAfterLongWarmUp() 2974 { 2975 return clipThreshold( 2976 Options::thresholdForOptimizeAfterLongWarmUp() * 2977 optimizationThresholdScalingFactor() * 2978 (1 << reoptimizationRetryCounter())); 2979 } 2980 2981 int32_t CodeBlock::counterValueForOptimizeSoon() 2982 { 2983 return clipThreshold( 2984 Options::thresholdForOptimizeSoon() * 2968 static_cast<double>(desiredThreshold) * 2985 2969 optimizationThresholdScalingFactor() * 2986 2970 (1 << reoptimizationRetryCounter())); … … 3019 3003 dataLog(*this, ": Optimizing after warm-up.\n"); 3020 3004 #if ENABLE(DFG_JIT) 3021 m_jitExecuteCounter.setNewThreshold(counterValueForOptimizeAfterWarmUp(), this); 3005 m_jitExecuteCounter.setNewThreshold( 3006 adjustedCounterValue(Options::thresholdForOptimizeAfterWarmUp()), this); 3022 3007 #endif 3023 3008 } … … 3028 3013 dataLog(*this, ": Optimizing after long warm-up.\n"); 3029 3014 #if ENABLE(DFG_JIT) 3030 m_jitExecuteCounter.setNewThreshold(counterValueForOptimizeAfterLongWarmUp(), this); 3015 m_jitExecuteCounter.setNewThreshold( 3016 adjustedCounterValue(Options::thresholdForOptimizeAfterLongWarmUp()), this); 3031 3017 #endif 3032 3018 } … … 3037 3023 dataLog(*this, ": Optimizing soon.\n"); 3038 3024 #if ENABLE(DFG_JIT) 3039 m_jitExecuteCounter.setNewThreshold(counterValueForOptimizeSoon(), this); 3025 m_jitExecuteCounter.setNewThreshold( 3026 adjustedCounterValue(Options::thresholdForOptimizeSoon()), this); 3040 3027 #endif 3041 3028 }
Note:
See TracChangeset
for help on using the changeset viewer.