Changeset 121798 in webkit for trunk/Source/JavaScriptCore/bytecode/CodeBlock.h
- Timestamp:
- Jul 3, 2012, 12:19:22 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/bytecode/CodeBlock.h
r121717 r121798 686 686 return false; 687 687 unsigned value = rareCaseProfileForBytecodeOffset(bytecodeOffset)->m_counter; 688 return value >= Options::likelyToTakeSlowCaseMinimumCount && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold;688 return value >= Options::likelyToTakeSlowCaseMinimumCount() && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold(); 689 689 } 690 690 … … 694 694 return false; 695 695 unsigned value = rareCaseProfileForBytecodeOffset(bytecodeOffset)->m_counter; 696 return value >= Options::couldTakeSlowCaseMinimumCount && static_cast<double>(value) / m_executionEntryCount >= Options::couldTakeSlowCaseThreshold;696 return value >= Options::couldTakeSlowCaseMinimumCount() && static_cast<double>(value) / m_executionEntryCount >= Options::couldTakeSlowCaseThreshold(); 697 697 } 698 698 … … 714 714 return false; 715 715 unsigned specialFastCaseCount = specialFastCaseProfileForBytecodeOffset(bytecodeOffset)->m_counter; 716 return specialFastCaseCount >= Options::likelyToTakeSlowCaseMinimumCount && static_cast<double>(specialFastCaseCount) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold;716 return specialFastCaseCount >= Options::likelyToTakeSlowCaseMinimumCount() && static_cast<double>(specialFastCaseCount) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold(); 717 717 } 718 718 … … 724 724 unsigned specialFastCaseCount = specialFastCaseProfileForBytecodeOffset(bytecodeOffset)->m_counter; 725 725 unsigned value = slowCaseCount - specialFastCaseCount; 726 return value >= Options::likelyToTakeSlowCaseMinimumCount && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold;726 return value >= Options::likelyToTakeSlowCaseMinimumCount() && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold(); 727 727 } 728 728 … … 734 734 unsigned specialFastCaseCount = specialFastCaseProfileForBytecodeOffset(bytecodeOffset)->m_counter; 735 735 unsigned value = slowCaseCount + specialFastCaseCount; 736 return value >= Options::likelyToTakeSlowCaseMinimumCount && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold;736 return value >= Options::likelyToTakeSlowCaseMinimumCount() && static_cast<double>(value) / m_executionEntryCount >= Options::likelyToTakeSlowCaseThreshold(); 737 737 } 738 738 … … 956 956 void jitAfterWarmUp() 957 957 { 958 m_llintExecuteCounter.setNewThreshold(Options::thresholdForJITAfterWarmUp , this);958 m_llintExecuteCounter.setNewThreshold(Options::thresholdForJITAfterWarmUp(), this); 959 959 } 960 960 961 961 void jitSoon() 962 962 { 963 m_llintExecuteCounter.setNewThreshold(Options::thresholdForJITSoon , this);963 m_llintExecuteCounter.setNewThreshold(Options::thresholdForJITSoon(), this); 964 964 } 965 965 … … 992 992 unsigned reoptimizationRetryCounter() const 993 993 { 994 ASSERT(m_reoptimizationRetryCounter <= Options::reoptimizationRetryCounterMax );994 ASSERT(m_reoptimizationRetryCounter <= Options::reoptimizationRetryCounterMax()); 995 995 return m_reoptimizationRetryCounter; 996 996 } … … 999 999 { 1000 1000 m_reoptimizationRetryCounter++; 1001 if (m_reoptimizationRetryCounter > Options::reoptimizationRetryCounterMax )1002 m_reoptimizationRetryCounter = Options::reoptimizationRetryCounterMax ;1001 if (m_reoptimizationRetryCounter > Options::reoptimizationRetryCounterMax()) 1002 m_reoptimizationRetryCounter = Options::reoptimizationRetryCounterMax(); 1003 1003 } 1004 1004 1005 1005 int32_t counterValueForOptimizeAfterWarmUp() 1006 1006 { 1007 return Options::thresholdForOptimizeAfterWarmUp << reoptimizationRetryCounter();1007 return Options::thresholdForOptimizeAfterWarmUp() << reoptimizationRetryCounter(); 1008 1008 } 1009 1009 1010 1010 int32_t counterValueForOptimizeAfterLongWarmUp() 1011 1011 { 1012 return Options::thresholdForOptimizeAfterLongWarmUp << reoptimizationRetryCounter();1012 return Options::thresholdForOptimizeAfterLongWarmUp() << reoptimizationRetryCounter(); 1013 1013 } 1014 1014 … … 1090 1090 void optimizeSoon() 1091 1091 { 1092 m_jitExecuteCounter.setNewThreshold(Options::thresholdForOptimizeSoon << reoptimizationRetryCounter(), this);1092 m_jitExecuteCounter.setNewThreshold(Options::thresholdForOptimizeSoon() << reoptimizationRetryCounter(), this); 1093 1093 } 1094 1094 … … 1119 1119 uint32_t exitCountThresholdForReoptimization() 1120 1120 { 1121 return adjustedExitCountThreshold(Options::osrExitCountForReoptimization );1121 return adjustedExitCountThreshold(Options::osrExitCountForReoptimization()); 1122 1122 } 1123 1123 1124 1124 uint32_t exitCountThresholdForReoptimizationFromLoop() 1125 1125 { 1126 return adjustedExitCountThreshold(Options::osrExitCountForReoptimizationFromLoop );1126 return adjustedExitCountThreshold(Options::osrExitCountForReoptimizationFromLoop()); 1127 1127 } 1128 1128
Note:
See TracChangeset
for help on using the changeset viewer.