[PATCH 0/3] RISC-V: alignment in text sections

Jan Beulich jbeulich@suse.com
Mon Aug 12 15:06:40 GMT 2024


The other day I suggested to a co-worker to uniformly use ".insn 0"
to mark certain "bad" positions in code (Linux'es BUG() and alike).
Trying it out myself, I was surprised that I was unable to re-align
code after such a .insn use (or, equivalently, after .hword). I'm
aiming at fixing issues noticed in this area with this series.

1: process rs_align_code also when relaxing
2: correct alignment directive handling for text sections
3: odd data padding vs mapping symbols

However, this isn't quite enough yet. Tracking is now (I hope; maybe
better to say should now be) consistently per-section. Yet that's
still not fine-grained enough: It needs to be per-subsection. I'm
intending to clone x86'es respective handling to further address this
as well. Yet in the meantime the fixes here could already go in.

Jan


More information about the Binutils mailing list