This is the mail archive of the elfutils-devel@sourceware.org mailing list for the elfutils 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] Resolve ppc64 func descriptors as .func (via .opd)


On Tue, 11 Dec 2012 10:33:06 +0100, Jan Kratochvil wrote:
> This is the disagreement, so goint to write down here a question to IBM ABI
> authority, we can agree upon the question and send it.

Are you fine with the mail below?


Thanks,
Jan


------------------------------------------------------------------------------

To: binutils@sourceware.org
Subject: PowerPC64 ABI function descriptors question

Hello,

asking here for the IBM ppc64 ABI, unrelated to binutils itself.

elfutils should get a resolver of ppc64 .opd:
	[patch] Resolve ppc64 func descriptors as .func (via .opd)
	Message-ID: <20121009081320.GA1614@host2.jankratochvil.net>
	https://lists.fedorahosted.org/pipermail/elfutils-devel/2012-October/002650.html
	https://lists.fedorahosted.org/pipermail/elfutils-devel/2012-November/002743.html
	https://lists.fedorahosted.org/pipermail/elfutils-devel/2012-December/002798.html

So that the backtraces are readable on ppc64 such as:
# 0 0x10007fa8          __vmx__sigsetjmp_ent      | # 0 0x10007fa8          .raise
# 1 0x10008370 - 1      __vmx__sigsetjmp_ent      | # 1 0x10008370 - 1      .abort
# 2 0x10001344 - 1      (null)                    | # 2 0x10001344 - 1      .sigusr2
(the addresses in backtrace are entry points, not function descriptors)

I would not like to break / confuse ppc64 ABI naming so asking here.

FYI elfutils address -> name resolver (dwfl_module_addrsym) currently does not
/ cannot use DWARF, we talk only about ELF symbols.

Should the backtrace resolved names be dot-prefixed (".raise") or not ("raise")?

http://refspecs.linuxfoundation.org/ELF/ppc64/PPC-elf64abi-1.9.html#FUNC-DES
says they should be dot-prefixed - as they are ELF symbols.

But usually in GDB the backtrace is without dots
	#0 raise
	#1 abort
	#2 sigusr2
as DWARF symbols get used instead and DWARF does not use the dot prefix.

If elfutils had name -> address resolver (still without DWARF capability) which
address should be resolved for "raise"?  Should be ".raise" also resolved?

It is clear that BFD currently uses:
	raise for ELF function descriptor
	.raise for ELF code entry point
	raise for DWARF code entry point, overriding the ELF function descriptor

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