]> git.ipfire.org Git - thirdparty/gcc.git/commit
LoongArch: Delete macro definition ASM_OUTPUT_ALIGN_WITH_NOP.
authorLulu Cheng <chenglulu@loongson.cn>
Fri, 15 Sep 2023 03:56:01 +0000 (11:56 +0800)
committerLulu Cheng <chenglulu@loongson.cn>
Tue, 17 Oct 2023 01:59:11 +0000 (09:59 +0800)
commitb20c7ee066cb7d952fa193972e8bc6362c6e4063
tree40c9c9c9b48adff46c24ef6914b1b6f2a6bc20ed
parentb25b43caf2503a160a928d61318dff837efabd97
LoongArch: Delete macro definition ASM_OUTPUT_ALIGN_WITH_NOP.

There are two reasons for removing this macro definition:
1. The default in the assembler is to use the nop instruction for filling.
2. For assembly directives: .align [abs-expr[, abs-expr[, abs-expr]]]
   The third expression it is the maximum number of bytes that should be
   skipped by this alignment directive.
   Therefore, it will affect the display of the specified alignment rules
   and affect the operating efficiency.

This modification relies on binutils commit 1fb3cdd87ec61715a5684925fb6d6a6cf53bb97c.
(Since the assembler will add nop based on the .align information when doing relax,
it will cause the conditional branch to go out of bounds during the assembly process.
This submission of binutils solves this problem.)

gcc/ChangeLog:

* config/loongarch/loongarch.h (ASM_OUTPUT_ALIGN_WITH_NOP):
Delete.

Co-authored-by: Chenghua Xu <xuchenghua@loongson.cn>
gcc/config/loongarch/loongarch.h