[llvm] Reland "[ObjectYAML][ELF] Take alignment into account when generating notes" (PR #118434)

James Henderson via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 4 00:27:59 PST 2024


https://github.com/jh7370 commented:

> Aligning notes to anything other than 4 or 8 makes no sense, because parsers would not be able to read them correctly. If a test writer needs a nonsense notes section, they can always use `Content:` instead of `Notes:`. Some existing tests even do this, for example, `tools/llvm-objcopy/ELF/only-keep-debug.test` and `tools/llvm-readobj/ELF/note-alignment-invalid.test`.

That's fair, thanks (I'm less concerned about generating something parsers could read with this, but the point about being able to use `Content` for invalid data is compelling enough for me).

https://github.com/llvm/llvm-project/pull/118434


More information about the llvm-commits mailing list