This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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 08/11] ELFv2 ABI: no function descriptors


> ChangeLog:
> 
> 	* ppc-linux-tdep.c (ppc_linux_init_abi): Only call
> 	set_gdbarch_convert_from_func_ptr_addr and
> 	set_gdbarch_elf_make_msymbol_special for ELFv1.
> 	* ppc-sysv-tdep.c (ppc64_sysv_abi_push_param): Only handle
> 	function descriptors on ELFv1.
> 	(ppc64_sysv_abi_push_dummy_call): Likewise.  On ELFv2,
> 	set up r12 at function entry.

Interesting change in ABI (which I really like :))!

Just a small request...

> -	/* The TOC is the second double word in the descriptor.  */
> -	CORE_ADDR toc =
> -	  read_memory_unsigned_integer (desc_addr + tdep->wordsize,
> -					tdep->wordsize, byte_order);
> -	regcache_cooked_write_unsigned (regcache,
> -					tdep->ppc_gp0_regnum + 2, toc);
> -      }
> -  }
[...]
> +	{
> +	  /* The TOC is the second double word in the descriptor.  */
> +	  CORE_ADDR toc =
> +	    read_memory_unsigned_integer (desc_addr + tdep->wordsize,
> +					  tdep->wordsize, byte_order);
> +	  regcache_cooked_write_unsigned (regcache,

While touching this code, would you mind adding the empty line
after the variable declaration?

Thank you,
-- 
Joel


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