Announcement

Collapse
No announcement yet.

Python Can Run Up To ~27% Faster On Fedora 32 With Optimization

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Python Can Run Up To ~27% Faster On Fedora 32 With Optimization

    Phoronix: Python Can Run Up To ~27% Faster On Fedora 32 With Optimization

    Python scripts may be running noticeably faster come the release of Fedora 32 in April...

    http://www.phoronix.com/scan.php?pag...thon-Optimized

  • #2
    LD_PRELOAD is used by both fakeroot/pseudo and libeatmydata, so this could actually be an issue...

    Comment


    • #3
      There is a list of software that do not play nicely with this flags at gentooLTO.
      Save me a lot of times rather than testing each self added flags whenever I failed to build the software.

      Comment


      • #4
        This doesn't break only with LD_PRELOAD, lol. It breaks if the underlying implementation of the function ever changes, but not its interface (obviously).

        As an example, suppose the compiler decides to inline a specific implementation of 'free' but not 'malloc'. Later 'malloc' changes its implementation to use a more efficient data structure but keeping same interface, obviously. And you don't recompile your code.

        Your code will call the new malloc automatically since it called it before, but then it will use the old inlined 'free' with the old data structure and crash. It's a dynamic library, not a static library.

        It should only be safe with self-hosted libraries by a project or Python, which are always rebuilt only when the entire thing is rebuilt.

        Comment


        • #5
          Originally posted by ernstp View Post
          LD_PRELOAD is used by both fakeroot/pseudo and libeatmydata, so this could actually be an issue...
          The former isn't really an issue with Fedora because it doesn't use fakeroot.

          and if you really need something like fakeroot, you should just use containers.

          Comment


          • #6
            it would be interesting to see performance comparisons between Anaconda, Intel's distribution of python (releases as an Anaconda distro), and Pythons of different independent distros...

            Comment


            • #7
              Python needs a jit compiler (even if just for popular archs like x64 and arm64). It would double the performance. Every friggin browser has one nowadays.

              Comment


              • #8
                I use Python with tsocks, guess I won't be doing that with native Python on Fedora anymore.

                Comment


                • #9
                  Originally posted by log0 View Post
                  Python needs a jit compiler (even if just for popular archs like x64 and arm64). It would double the performance. Every friggin browser has one nowadays.
                  That's PyPy.

                  Comment


                  • #10
                    I think some people may be mis-interpreting the LD_PRELOAD issue. This would only impact the ability to override libpython symbols (which is expected to be a very tiny use case). Symbols in (for example) glibc would still be able to be overridden.

                    Comment

                    Working...
                    X