[Lldb-commits] [PATCH] D133036: [InstCombine] Treat passing undef to noundef params as UB

2023-02-21 Thread Tim Neumann via Phabricator via lldb-commits
TimNN added a comment. Herald added a subscriber: StephenFan. The ThinLTO related breakage I mentioned above should be fixed as of https://github.com/llvm/llvm-project/commit/451799bb8261bde52bbfef226d019caf1d82aa42. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://rev

[Lldb-commits] [PATCH] D133036: [InstCombine] Treat passing undef to noundef params as UB

2022-11-13 Thread Tim Neumann via Phabricator via lldb-commits
TimNN added a comment. I'm sorry for the noise. Further investigation has shown that this happens when Rust is doing (thin) LTO, and I don't think this patch can be considered in any way "at fault" here, so this is the last you'll hear from me on the topic here. I don't know whether the fault i

[Lldb-commits] [PATCH] D133036: [InstCombine] Treat passing undef to noundef params as UB

2022-11-12 Thread Tim Neumann via Phabricator via lldb-commits
TimNN added a comment. I didn't manage to repro with `opt`, so still no compilable IR. I did some more debugging, though: - Inside `removeDeadArgumentsFromCallers`, `CB->getCalledFunction()->dump()` (after the modification) is `define void @_RNvXs0_NtNtCs840rfDNPFol_10proc_macro6bridge3rpchINt

[Lldb-commits] [PATCH] D133036: [InstCombine] Treat passing undef to noundef params as UB

2022-11-12 Thread Tim Neumann via Phabricator via lldb-commits
TimNN added a comment. I've included excerpts from the IR below. It will take me a bit to provide something compilable. Though you are right, the `noundef` did indeed get removed from the `call`. *** IR Dump Before DeadArgumentEliminationPass on [module] *** ; Function Attrs: nonlazybind uw

[Lldb-commits] [PATCH] D133036: [InstCombine] Treat passing undef to noundef params as UB

2022-11-12 Thread Tim Neumann via Phabricator via lldb-commits
TimNN added a comment. I'm still trying to properly minimize this, but this definitely interacts badly with other optimizations (which triggers the Rust CI failure I mentioned above): - We start with two functions, `outer` and `inner`. `outer` calls `inner`. `outer` has a `noundef` argument tha