Skip to content

Revert to default fullLTO on Clang #130048

Closed as not planned
Closed as not planned
@Fidget-Spinner

Description

@Fidget-Spinner

Feature or enhancement

Proposal:

Python 3.12 changed the default for Clang to ThinLTO. However, many people were unaware of this change and did not update their build scripts. This leaves a lot of perf on the table for macOS and possibly some other platforms.

  1. CPython was bitten by this: Python3.13 performance Issue with python.org macOS installers on ARM Macs #122580
  2. Faster CPython was bitten by this: clang builds not using full LTO faster-cpython/bench_runner#342
  3. python-build-standalone (Astral) also seems to not have the fix: On Clang, LTO is ThinLTO, which leaves a lot of performance out for macOS astral-sh/python-build-standalone#528
  4. msys2/mingw also seems to have not noticed: python: build with full lto msys2/MINGW-packages#23384

This seems to be confusing and tripping up a lot of people. I propose we change the --with-lto default back to full.

cc @brandtbucher @corona10

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    buildThe build process and cross-buildtype-featureA feature request or enhancement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions