[ELF] Delete redundant pageAlign at PT_GNU_RELRO boundaries after D58892
authorFangrui Song <maskray@google.com>
Wed, 17 Jul 2019 09:23:04 +0000 (09:23 +0000)
committerFangrui Song <maskray@google.com>
Wed, 17 Jul 2019 09:23:04 +0000 (09:23 +0000)
commit2be0ebb0d80d75241ac7ef033153466317ff13a0
treed4577ac91498d556ad214adc85f03790c9d3a4f3
parent9eb95903da4575b3b95d1a743d48e51bb5026ccd
[ELF] Delete redundant pageAlign at PT_GNU_RELRO boundaries after D58892

Summary:
After D58892 split the RW PT_LOAD on the PT_GNU_RELRO boundary, the new
layout is:

PT_LOAD(PT_GNU_RELRO(.data.rel.ro .bss.rel.ro)) PT_LOAD(.data. .bss)

The two pageAlign() calls at PT_GNU_RELRO boundaries are redundant due
to the existence of PT_LOAD.

Reviewers: grimar, peter.smith, ruiu, espindola

Reviewed By: ruiu

Subscribers: sfertile, atanasyan, emaste, arichardson, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64854

llvm-svn: 366307
lld/ELF/Writer.cpp