[PATCH] D43690: [ThinLTO] Keep available_externally symbols live

Xin Tong via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 20 10:30:58 PDT 2018


trentxintong added a comment.

In https://reviews.llvm.org/D43690#1206049, @vlad.tsyrklevich wrote:

> In https://reviews.llvm.org/D43690#1201965, @twoh wrote:
>
> > Hello, I wonder if we need to keep linkonce_odr symbols live here as well. I observe a case that a vtable for template class initiated has linkonce_odr linkage and marked dead here, which results compiler crash at WholeProgramDevirt because the global variable for vtable doesn't have initializer (https://github.com/llvm-mirror/llvm/blob/master/lib/Transforms/IPO/WholeProgramDevirt.cpp#L676 assumes that GV has the initializer). Thanks!
>
>
> I'm not sure why a linkonce_odr GV would be marked non-prevailing. Do you have a minimized example to look at?


Hi @vlad.tsyrklevich, @twoh

I am working on creating a reduced test case. Will get back to you.
Thanks

In https://reviews.llvm.org/D43690#1206049, @vlad.tsyrklevich wrote:

> In https://reviews.llvm.org/D43690#1201965, @twoh wrote:
>
> > Hello, I wonder if we need to keep linkonce_odr symbols live here as well. I observe a case that a vtable for template class initiated has linkonce_odr linkage and marked dead here, which results compiler crash at WholeProgramDevirt because the global variable for vtable doesn't have initializer (https://github.com/llvm-mirror/llvm/blob/master/lib/Transforms/IPO/WholeProgramDevirt.cpp#L676 assumes that GV has the initializer). Thanks!
>
>
> I'm not sure why a linkonce_odr GV would be marked non-prevailing. Do you have a minimized example to look at?





Repository:
  rL LLVM

https://reviews.llvm.org/D43690





More information about the llvm-commits mailing list