]> git.lizzy.rs Git - rust.git/commit
rustc_codegen_llvm: Restore the closure env alloca hack for LLVM 5.
authorJosh Stone <jistone@redhat.com>
Thu, 9 Aug 2018 23:35:25 +0000 (16:35 -0700)
committerJosh Stone <jistone@redhat.com>
Thu, 9 Aug 2018 23:35:25 +0000 (16:35 -0700)
commit763e72110a913c7aab396a0f687e2ebd3c9e572a
treebe36e53ca677d070717833a4badaac20c3632765
parentb73535f1e9c46a698527fab51b1cc9fad3f53412
rustc_codegen_llvm: Restore the closure env alloca hack for LLVM 5.

This hack was removed in #50949, but without it I found that building
`std` with full debuginfo would print many LLVM `DW_OP_LLVM_fragment`
errors, then die `LLVM ERROR: Failed to strip malformed debug info`.

It doesn't seem to be a problem for LLVM 6, so we can re-enable the hack
just for older LLVM.

This reverts commit da579ef75e4a8ca11fb98b24a0a3ea0c7ccffeeb.
Fixes #53204.
r? @eddyb
src/librustc_codegen_llvm/mir/mod.rs