[PATCH] D29278: [ELF] Bypass section type check #2

Rafael Avila de Espindola via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 30 09:49:10 PST 2017


ben via Phabricator <reviews at reviews.llvm.org> writes:

> bd1976llvm added a comment.
>
> I think these checks exist, because of this line from the gabi.
>
>   In the first phase, input sections that match in name, type and attribute flags should be concatenated into single sections.
>
> However, it should be noted that this is followed by an note that states that linkers are only **recommended ** to follow this approach.
>
> AFAIR: at least gnu does not follow this rule. Also, I am aware of many codebases (games) with hand written asm which does not set the section flags correctly. This is not always easy to fix. Perhaps this asm is in a third party library etc..
>
> Being permissive on this can be very helpful to users.

And that is the idea of the white list. It makes us as permissive as we
need. I also don't see the point for different levels depending on
linker scripts being used or not.

Cheers,
Rafael


More information about the llvm-commits mailing list