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 1/6] gold: Add 2 overloaded functions to copy_reloc.


>         * copy-relocs.h (Copy_relocs::copy_reloc): New declaration of overloaded function.
>         (Copy_relocs::save): Likewise.
>         * copy-relocs.cc (Copy_relocs::copy_reloc): New definition of overloaded function.
>         (Copy_relocs::save): Likewise.

Rather than overload the copy_reloc() method, I've chosen to remove
the dependency on the relocation format from the Copy_relocs class
entirely, and update all targets to pass r_type, r_offset, and
r_addend separately.

I've committed the attached patch.

-cary


2015-11-09  Cary Coutant  <ccoutant@gmail.com>
            Vladimir Radosavljevic <Vladimir.Radosavljevic@imgtec.com>

gold/
        * copy-relocs.h (Copy_relocs::copy_reloc): Replace reloc parameter
        with type, offset, addend.
        (Copy_relocs::save): Likewise.
        * copy-relocs.cc (Copy_relocs::copy_reloc): Likewise.
        (Copy_relocs::save): Likewise.
        * aarch64.cc (Target_aarch64::copy_reloc): Pass r_type, r_offset,
        and r_addend to Copy_relocs::copy_reloc.
        * arm.cc (Target_arm::copy_reloc): Likewise.
        * i386.cc (Target_i386::copy_reloc): Likewise.
        * mips.cc (Target_mips::copy_reloc): Likewise.
        * powerpc.cc (Target_powerpc::copy_reloc): Likewise.
        * s390.cc (Target_s390::copy_reloc): Likewise.
        * sparc.cc (Target_sparc::copy_reloc): Likewise.
        * tilegx.cc (Target_tilegx::copy_reloc): Likewise.
        * x86_64.cc (Target_x86_64::copy_reloc): Likewise.

Attachment: copy-reloc.patch
Description: Binary data


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