This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 2/2] binutils/testsuite: Verify the handling of invalid `r_sym' in relocation


Hi Maciej,

> 	binutils/
> 	* testsuite/binutils-all/strip-14.d: New test.
> 	* testsuite/binutils-all/strip-14rel.s: New test source.
> 	* testsuite/binutils-all/strip-14rela.s: New test source.
> 	* testsuite/binutils-all/strip-14mips64.s: New test source.
> 	* testsuite/binutils-all/objcopy.exp: Run the new test.

>  OK to apply?

Approved - but ...

> +    if { [istarget "aarch64*-*"] } {
> +	set reloc 259
> +    } elseif { [istarget "ia64*-*"] \
> +	       || [istarget "m32r*-*"] \
> +	       || [istarget "v850*-*"] } {
> +	set reloc 50
> +    } else {
> +	set reloc 1
> +    }

I think that you should add a comment at the start of this if-statement
explaining why a reloc number is being chosen.  That way future readers
of the code will understand what is going on.

Cheers
  Nick


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]