[Patch] ld: check for address space overflow

Tristan Gingold gingold@adacore.com
Wed Mar 15 09:26:00 GMT 2017


> On 15 Mar 2017, at 02:11, Alan Modra <amodra@gmail.com> wrote:
> 
> On Tue, Mar 14, 2017 at 02:56:18PM +0100, Tristan Gingold wrote:
>>    	* testsuite/ld-checks/checks.exp (overflow_check): Disable for
>>    	non-elf targets.
> 
> OK.

Thanks, committed.

>  I'm going to commit the following too.  h8300 and ip2k targets
> use a 16-bit address cpu by default, so hit the address wrap check
> (more than once) on the 64k section test.
> 
> 	* testsuite/ld-elf/sec64k.exp: Don't run on h8300 and ip2k.

Thank you for the head-up.
Maybe the overflow check should also check that the length is not larger than the address space (otherwise it could have missed these h8300 and ip2k cases), but I think this is a too artificial case.

Tristan.



More information about the Binutils mailing list