[PATCH] D75518: [MC][ELF] Allow section directives with empty flags

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 3 13:14:07 PST 2020


MaskRay added a comment.

Copied from https://github.com/ClangBuiltLinux/linux/issues/913#issuecomment-594157005

See https://lists.llvm.org/pipermail/llvm-dev/2020-February/139390.html

https://reviews.llvm.org/D73999 added the error. I agree that the error message is not great but there is some technical difficulty there. I have noted we should improve it.

  .section .foo,"ax", at progbits; .byte 1
  .section .foo,"", at progbits; .byte 2
  .section .foo,"a", at progbits; .byte 3

So GNU as does not error for the empty flags case.

  a.s:3: Error: changed section attributes for .foo

Can you send an email to binutils at sourceware.org asking whether this is intended case?
Cite https://sourceware.org/ml/binutils/2020-02/msg00129.html for reference.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75518/new/

https://reviews.llvm.org/D75518





More information about the llvm-commits mailing list