GNU Binutils with patches for OS216
修訂 | ad7b71d775d5cf07a4c58363c8a97e1aad4dc26f (tree) |
---|---|
時間 | 2003-06-14 08:03:59 |
作者 | Jim Blandy <jimb@code...> |
Commiter | Jim Blandy |
* ppc-linux-tdep.c (ppc64_desc_entry_point): New function.
(ppc64_standard_linkage_target): Use it.
@@ -1,5 +1,8 @@ | ||
1 | 1 | 2003-06-13 Jim Blandy <jimb@redhat.com> |
2 | 2 | |
3 | + * ppc-linux-tdep.c (ppc64_desc_entry_point): New function. | |
4 | + (ppc64_standard_linkage_target): Use it. | |
5 | + | |
3 | 6 | * solib-svr4.c (solib_break_names): Recognize the 64-bit PowerPC |
4 | 7 | Linux entry point symbols for _dl_debug_state, too. |
5 | 8 |
@@ -731,6 +731,16 @@ insn_ds_field (unsigned int insn) | ||
731 | 731 | } |
732 | 732 | |
733 | 733 | |
734 | +/* If DESC is the address of a 64-bit PowerPC Linux function | |
735 | + descriptor, return the descriptor's entry point. */ | |
736 | +static CORE_ADDR | |
737 | +ppc64_desc_entry_point (CORE_ADDR desc) | |
738 | +{ | |
739 | + /* The first word of the descriptor is the entry point. */ | |
740 | + return (CORE_ADDR) read_memory_unsigned_integer (desc, 8); | |
741 | +} | |
742 | + | |
743 | + | |
734 | 744 | /* Pattern for the standard linkage function. These are built by |
735 | 745 | build_plt_stub in elf64-ppc.c, whose GLINK argument is always |
736 | 746 | zero. */ |
@@ -865,7 +875,7 @@ ppc64_standard_linkage_target (CORE_ADDR pc, unsigned int *insn) | ||
865 | 875 | + insn_ds_field (insn[2])); |
866 | 876 | |
867 | 877 | /* The first word of the descriptor is the entry point. Return that. */ |
868 | - return (CORE_ADDR) read_memory_unsigned_integer (desc, 8); | |
878 | + return ppc64_desc_entry_point (desc); | |
869 | 879 | } |
870 | 880 | |
871 | 881 |