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: [GOLD] relocate() params


> So this is how the relocate() reorganization looks.
>
>         * object.h (struct Relocate_info): Add "rr".
>         * reloc.h (Relocatable_relocs::set_strategy): New accessor.
>         * reloc.cc (Sized_relobj_file::do_relocate_sections): Init
>         relinfo.rr for relocate_section and relocate_relocs.
>         * powerpc.cc (relocate): Add rel_type and preloc parameters.
>         Delete rela and r_type params, instead recalculate these from
>         preloc.
>         (relocate_relocs): Delete Relocatable_relocs* param, instead
>         use relinfo->rr.
>         * aarch64.cc: Likewise.
>         * arm.cc: Likewise.
>         * i386.cc: Likewise.
>         * mips.cc: Likewise.
>         * s390.cc: Likewise.
>         * sparc.cc: Likewise.
>         * target.h: Likewise.
>         * tilegx.cc: Likewise.
>         * x86_64.cc: Likewise.
>         * testsuite/testfile.cc: Likewise.
>         * target-reloc.h (relocate_section): Adjust to suit.
>         (apply_relocation, relocate_relocs): Likewise.

This looks good. In particular, I like how it cleans up the overloads
of Relocate::relocate() in the MIPS backend. We now have an extra
instantiation of the Rel/Rela accessor, but I'm pretty sure that's
zero cost in optimized code.

Thanks!

Sigh; my work-in-progress is not going to merge cleanly after this. I
should make you wait until I commit :-).

-cary


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