Skip to content

Commit 471a043

Browse files
committed
[AArch64][ELF] Section alignment of 4 for AArch64 instruction
The integrated assembler sets a minimum alignment for the .text section of 4. However user defined sections get an alignment of 1. Unlike the GNU assembler which raises the section alignment to 4 if an AArch64 instruction is used, the integrated assembler leaves the alignment at 1
1 parent 262d8cf commit 471a043

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

llvm/lib/Target/AArch64/MCTargetDesc/AArch64ELFStreamer.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,6 @@ class AArch64ELFStreamer : public MCELFStreamer {
329329
// Section alignment of 4 to match GNU Assembler
330330
if ((Section->getAlign() < 4) && Section->isText()) {
331331
Section->setAlignment(Align(4));
332-
emitValueToAlignment(Align(4), 0, 1, 0);
333332
}
334333
}
335334

0 commit comments

Comments
 (0)