3 ms·
Anyone comment the obvious low hanging fruit? Compile CPython in release mode, as most everyone uses the debug version. Doing this gives a rough 10% performan
by whb07 6y ago
Anyone comment the obvious low hanging fruit?
Compile CPython in release mode, as most everyone uses the debug version.
Doing this gives a rough 10% performance increase.
- macjohnmcc 6y agoI've compiled some code using Microsoft tools and saw some huge performance gains on code I didn't think would benefit.
- sgerenser 6y agoIf you’re talking about Debug vs Release mode in Visual Studio, there’s a huge performance hit with STL iterators in Debug mode. Like sometimes 10-20x slower for tight loops. This is obviously C++ not C, so it doesn’t apply to Python directly. But in general toolchains can have very unoptimized code paths in debug mode.
- kzrdude 6y agoThis seems like a joke? CPython uses a threaded interpreter loop, so surely they optimize the release build?