Compile with -O2
instead of -O3
#140
Replies: 4 comments
-
Red Hat's and Fedora's Python are compiled with
Florian also suggests to try
(The blog post has a typo. I have informed Florian that the correct spelling is |
Beta Was this translation helpful? Give feedback.
-
Awesome, thanks for the link! I'll find time today to try that out. |
Beta Was this translation helpful? Give feedback.
-
Looks like
|
Beta Was this translation helpful? Give feedback.
-
So |
Beta Was this translation helpful? Give feedback.
-
On a hunch, I tried compiling CPython with
-O2
… which results in a 1% speedup.If I had to attribute this to anything, I’d guess that it’s because
-O3
’s aggressive inlining and loop unrolling hurts i-cache locality (the-O2
executable is ~3.5% smaller than the-O3
one).Beta Was this translation helpful? Give feedback.
All reactions