[PATCH] D23447: [ELF] - Do not use mergeable sections when LS is used.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 12 06:18:36 PDT 2016


grimar added a comment.

In https://reviews.llvm.org/D23447#513728, @davide wrote:

> In https://reviews.llvm.org/D23447#513726, @grimar wrote:
>
> > In https://reviews.llvm.org/D23447#513725, @davide wrote:
> >
> > > This seems to me just a way to avoid a bug, that needs to be fixed.
> >
> >
> > We use the same for -O0 currently. Of cource it should be implemented, but for now that is easy way to go forward in supporting LS.
>
>
> That's a completely different story. -O0 has an explicit semantic which is "linker please do not optimize my code".
>  Here we're silently skipping the optimization because nobody implemented the correct support for it. So, sure, you can do this as temporary workaround (although I disagree because it hides a bug), but I wouldn't say that "we do this at -O0" is a justification for this or being sloppy.


I think "we do that for -O0" is a justification for correctness of the change. Main reason for this is to let kernel to link. More complex change will need more time for reviews and I think we can use this one as temporarily solution.


https://reviews.llvm.org/D23447





More information about the llvm-commits mailing list