diff options
Diffstat (limited to 'Source/JavaScriptCore/bytecode/ExecutionCounter.cpp')
-rw-r--r-- | Source/JavaScriptCore/bytecode/ExecutionCounter.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/Source/JavaScriptCore/bytecode/ExecutionCounter.cpp b/Source/JavaScriptCore/bytecode/ExecutionCounter.cpp index 1f2e8260a..12a404981 100644 --- a/Source/JavaScriptCore/bytecode/ExecutionCounter.cpp +++ b/Source/JavaScriptCore/bytecode/ExecutionCounter.cpp @@ -144,13 +144,7 @@ bool ExecutionCounter::setThreshold(CodeBlock* codeBlock) return true; } - int32_t maxThreshold; - if (Options::randomizeExecutionCountsBetweenCheckpoints) - maxThreshold = codeBlock->globalObject()->weakRandomInteger() % Options::maximumExecutionCountsBetweenCheckpoints; - else - maxThreshold = Options::maximumExecutionCountsBetweenCheckpoints; - if (threshold > maxThreshold) - threshold = maxThreshold; + threshold = clippedThreshold(codeBlock->globalObject(), threshold); m_counter = static_cast<int32_t>(-threshold); |