Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

debuginfo: add compiler option to allow compressed debuginfo sections #115358

Merged
merged 6 commits into from
Sep 9, 2023

Commits on Sep 8, 2023

  1. lto: load bitcode sections by name

    Upstream change
    llvm/llvm-project@6b539f5 changed
    `isSectionBitcode` works and it now only respects `.llvm.lto` sections
    instead of also `.llvmbc`, which it says was never intended to be used
    for LTO. We instead load sections by name, and sniff for raw bitcode by
    hand.
    
    r? @nikic
    @rustbot label: +llvm-main
    durin42 committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    942bdf9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    9ad0396 View commit details
    Browse the repository at this point in the history
  3. debuginfo: add compiler option to allow compressed debuginfo sections

    LLVM already supports emitting compressed debuginfo. In debuginfo=full
    builds, the debug section is often a large amount of data, and it
    typically compresses very well (3x is not unreasonable.) We add a new
    knob to allow debuginfo to be compressed when the matching LLVM
    functionality is present. Like clang, if a known-but-disabled
    compression mechanism is requested, we disable compression and emit
    uncompressed debuginfo sections.
    
    The API is different enough on older LLVMs we just pretend the support
    is missing on LLVM older than 16.
    durin42 committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    af9e550 View commit details
    Browse the repository at this point in the history
  4. options: fix indentation

    rustfmt didn't save me here, sigh
    durin42 committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    ed17b56 View commit details
    Browse the repository at this point in the history
  5. sort

    durin42 committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    a52990b View commit details
    Browse the repository at this point in the history
  6. tests: use warning output from rustc to catch missing compression

    Using `ld.lld` may have been clever, but that was getting the /system/
    ld.lld, not one we may have built as part of building llvm. By using the
    warning message coming directly from rustc we now correctly skip the
    zlib and zstd tests when the support is missing.
    durin42 committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    78d805c View commit details
    Browse the repository at this point in the history