Author vstinner
Recipients Mark.Shannon, inada.naoki, jdemeyer, josh.r, malin, vstinner
Date 2019-08-13.15:50:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Few more links about likely/__builtin_expect:

* GCC documentation says: "In general, you should prefer to use actual profile feedback for this (-fprofile-arcs), as programmers are notoriously bad at predicting how their programs actually perform."


  "If you're writing for x86/x64 (and are not using 20-year-old CPUs), the performance gain from using __builtin_expect() will be negligible if any."


  "This optimized version [PGO] runs significantly faster (...) than our version that used __builtin_expect()."

  [When __builtin_expect() is misused] "In this case, unsurprisingly, we made each check run slower (...)"


  "Like all such performance optimisations you should only do it after extensive profiling to ensure the code really is in a bottleneck (...)"

Date User Action Args
2019-08-13 15:50:21vstinnersetrecipients: + vstinner, inada.naoki, Mark.Shannon, jdemeyer, josh.r, malin
2019-08-13 15:50:21vstinnersetmessageid: <>
2019-08-13 15:50:21vstinnerlinkissue37774 messages
2019-08-13 15:50:20vstinnercreate