Changeset 243857 in webkit
- Timestamp:
- Apr 3, 2019, 10:27:25 PM (7 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 4 edited
-
ChangeLog (modified) (1 diff)
-
runtime/Options.cpp (modified) (1 diff)
-
runtime/Options.h (modified) (1 diff)
-
runtime/RandomizingFuzzerAgent.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r243853 r243857 1 2019-04-03 Yusuke Suzuki <ysuzuki@apple.com> 2 3 Unreviewed, rolling in r243843 with the build fix 4 https://bugs.webkit.org/show_bug.cgi?id=196586 5 6 * runtime/Options.cpp: 7 (JSC::recomputeDependentOptions): 8 * runtime/Options.h: 9 * runtime/RandomizingFuzzerAgent.cpp: 10 (JSC::RandomizingFuzzerAgent::getPrediction): 11 1 12 2019-04-03 Ryan Haddad <ryanhaddad@apple.com> 2 13 -
trunk/Source/JavaScriptCore/runtime/Options.cpp
r243853 r243857 452 452 || Options::verboseCFA() 453 453 || Options::verboseDFGFailure() 454 || Options::verboseFTLFailure()) 454 || Options::verboseFTLFailure() 455 || Options::dumpRandomizingFuzzerAgentPredictions()) 455 456 Options::alwaysComputeHash() = true; 456 457 -
trunk/Source/JavaScriptCore/runtime/Options.h
r243853 r243857 437 437 v(bool, useRandomizingFuzzerAgent, false, Normal, nullptr) \ 438 438 v(unsigned, seedOfRandomizingFuzzerAgent, 1, Normal, nullptr) \ 439 v(bool, dumpRandomizingFuzzerAgentPredictions, false, Normal, nullptr) \ 439 440 \ 440 441 v(bool, logPhaseTimes, false, Normal, nullptr) \ -
trunk/Source/JavaScriptCore/runtime/RandomizingFuzzerAgent.cpp
r243853 r243857 27 27 #include "RandomizingFuzzerAgent.h" 28 28 29 #include "CodeBlock.h" 30 29 31 namespace JSC { 30 32 … … 34 36 } 35 37 36 SpeculatedType RandomizingFuzzerAgent::getPrediction(CodeBlock* , int, SpeculatedType)38 SpeculatedType RandomizingFuzzerAgent::getPrediction(CodeBlock* codeBlock, int bytecodeIndex, SpeculatedType original) 37 39 { 38 40 auto locker = holdLock(m_lock); 39 41 uint32_t high = m_random.getUint32(); 40 42 uint32_t low = m_random.getUint32(); 41 uint64_t result = (static_cast<uint64_t>(high) << 32) | low; 42 return static_cast<SpeculatedType>(result) & SpecFullTop; 43 SpeculatedType generated = static_cast<SpeculatedType>((static_cast<uint64_t>(high) << 32) | low) & SpecFullTop; 44 if (Options::dumpRandomizingFuzzerAgentPredictions()) 45 dataLogLn("getPrediction name:(", codeBlock->inferredName(), "#", codeBlock->hashAsStringIfPossible(), "),bytecodeIndex:(", bytecodeIndex, "),original:(", SpeculationDump(original), "),generated:(", SpeculationDump(generated), ")"); 46 return generated; 43 47 } 44 48
Note:
See TracChangeset
for help on using the changeset viewer.