[PATCH] gold: pad code segments out to page size for isolate_execinstr targets

Roland McGrath mcgrathr@google.com
Tue Aug 27 21:55:00 GMT 2013


Committed.

I like the simplicity of one-byte nops and don't really know what the
benefit of longer ones is.
But moreover, I intend to keep gold's behavior in partiy with BFD
ld's, and in BFDland it is more hassle to change the signature of the
hook so I didn't consider bothering with it.

I considered doing code fill with HLT, but hesitated for two reasons.
First, while I cannot really imagine a sensical situation in which
code fill instructions would be executed, I'm not completely confident
it never could validly be executed.
Second, I'd like to keep x86 and ARM at parity in this sort of regard,
and in BFDland ARM does default zero-fill (which is not quite a nop in
ARM, but a harmless enough instruction) so it would be a bunch more
work to change code fill for arm-nacl in BFD (which I'd do before
making gold match).


Thanks,
Roland



More information about the Binutils mailing list