[PATCH] D133452: [ORC] Fix auto-claim of weak defs in ObjectLinkingLayer

Lang Hames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 22 10:19:55 PDT 2022


lhames added a comment.

In D133452#3795518 <https://reviews.llvm.org/D133452#3795518>, @Hahnfeld wrote:

> In D133452#3782574 <https://reviews.llvm.org/D133452#3782574>, @lhames wrote:
>
>> I think I botched the commit message for that commit and that might be contributing to the confusion: Prior to that commit any weak symbol that was //referenced in the graph//, but //wasn't// in the responsibility set was turned into an external symbol (not dead-stripped, as the commit message says). That would result in a missing definition error within the graph containing the definition. That was definitely a bug, and the original commit fixed that issue.
>
> But then, what test case do I have to run to see the problem after reverting that commit locally?

As mentioned in the commit message, there was no testcase added because `lli` did not support JITLink at the time.

Stefan fixed that in 23973e0aac1e1 <https://reviews.llvm.org/rG23973e0aac1e13eecebc62547585815e8352f65c>, so now you should be able to run

  lli -relocation-model=pic -jit-linker eh.ll

where eh.ll is the IR for your testcase.

>> Can you share the IR that you're feeding in? I'd like to try to reproduce this and understand what's going on.
>
> I posted the C++ code above, just compile with `clang++ -target riscv64-unknown-linux-gnu -S -emit-llvm throw.cpp`...

Thanks! I should be able to take a look this weekend.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D133452/new/

https://reviews.llvm.org/D133452



More information about the llvm-commits mailing list