[PATCH] D22813: [ELF] Linkerscript: implement DATA_SEGMENT_RELRO_END.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 26 10:05:38 PDT 2016


grimar added a comment.

In https://reviews.llvm.org/D22813#496244, @ruiu wrote:

> It seems that it is not hard to implement exactly what is described in the document. Why don't you do that? Ignoring the parameters would be confusing.


We do not implement this behavior for lld without script (https://reviews.llvm.org/D20024).
Also I thing that requires 2 passes during assignAddress to calculate the required shift for DATA_SEGMENT_ALIGN, so it is not so simple also.
(First pass will iterate until meet the first non relro section and calculate the shift, second should shift the location counter at DATA_SEGMENT_ALIGN position and reassign addresses again).
Implementing it as this patch do at least should allow this to work now without that overcomplication.


https://reviews.llvm.org/D22813





More information about the llvm-commits mailing list