Skip to content

Enabling LTO causes miscompilation on x86_64-apple-darwin #141306

Description

@briansmith

This is from https://github.com/briansmith/ring 's CI, testing the tip of the main branch. The CI passes on 1.86 and fails on multiple targets when building with 1.87. In at least one case, building and linking passes but the test fails, indicating potentially the code (computing HMAC) or the test of the code is being miscompiled.

Unfortunately, I have limited access to systems that would help me reduce these today. I have noticed another project has run into a similar linker error recently. I apologize in advance for such a poor bug report. I hope I, or ideally others, could fill in the details, as I have limited availability today.

x86_64-apple-darwin

https://github.com/briansmith/ring/actions/runs/15143648178/job/42573984175

running 2 tests
test hmac_debug ... ok
test hmac_tests ... FAILED

failures:

---- hmac_tests stdout ----

thread 'hmac_tests' panicked at tests/hmac_tests.rs:83:9:
assertion `left == right` failed
  left: true
 right: false
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

(The test is checking whether the output of the HMAC computation is correct.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.C-external-bugCategory: issue that is caused by bugs in software beyond our controlO-macosOperating system: macOSP-criticalCritical priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.llvm-fixed-upstreamIssue expected to be fixed by the next major LLVM upgrade, or backported fixesregression-untriagedUntriaged performance or correctness regression.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions