diff --git a/lld/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp b/lld/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp index 8e14eb3a6552..f06bd8ff151e 100644 --- a/lld/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp +++ b/lld/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp @@ -448,7 +448,7 @@ public: RDataSectionChunk(const File &linkedFile, SectionHeaderTableChunk *table) : SectionChunk(table, ".rdata", characteristics) { // The data section should be aligned to disk sector. - _align = 512; + _align = SECTOR_SIZE; // Extract executable atoms from the linked file and append them to this // section. @@ -478,7 +478,7 @@ public: DataSectionChunk(const File &linkedFile, SectionHeaderTableChunk *table) : SectionChunk(table, ".data", characteristics) { // The data section should be aligned to disk sector. - _align = 512; + _align = SECTOR_SIZE; // Extract executable atoms from the linked file and append them to this // section.