This is the mail archive of the
libffi-discuss@sourceware.org
mailing list for the libffi project.
Re: [gofrontend-dev] Re: [PATCH 00/13] Go closures, libffi, and the static chain
- From: Richard Henderson <rth at redhat dot com>
- To: libffi-discuss at sourceware dot org, gcc-patches at gcc dot gnu dot org, gofrontend-dev at googlegroups dot com
- Cc: Andreas Krebbel <krebbel at linux dot vnet dot ibm dot com>, Alan Modra <amodra at gmail dot com>
- Date: Thu, 11 Dec 2014 11:56:00 -0800
- Subject: Re: [gofrontend-dev] Re: [PATCH 00/13] Go closures, libffi, and the static chain
- Authentication-results: sourceware.org; auth=none
- References: <1412973773-3942-1-git-send-email-rth at redhat dot com> <20141211090623 dot GA30484 at linux dot vnet dot ibm dot com> <20141211092144 dot GE4283 at bubble dot grove dot modra dot org> <20141211103106 dot GA9789 at linux dot vnet dot ibm dot com> <20141211122519 dot GA26215 at linux dot vnet dot ibm dot com>
On 12/11/2014 04:25 AM, Dominik Vogt wrote:
> Update: If I disable the custom s390x code and switch to the
> implementation just using libffi for reflection calls, the same
> crash occurs with the testing/quick libgo test case. The called
> function sees a bogus value written by the synamic linker as the
> closure pointer, for example with this line in the test code:
>
> CheckEqual(fComplex64, fComplex64, nil)
The compiler should be generating a static structure for these.
On x86_64, I see
Relocation section '.rela.rodata.testing_quick.fComplex64$descriptor' at offset
0x5d4c0 contains 1 entries:
Offset Info Type Sym. Value Sym. Name + Addend
000000000000 000200000001 R_X86_64_64 0000000000000000 .text + c0
00000000000000c0 t quick.fComplex64
so that is in fact a direct relocation, and will not go via the dynamic linker.
Is the s390 port somehow putting the address of a plt entry here?
r~
- References:
- [PATCH 00/13] Go closures, libffi, and the static chain
- Re: [PATCH 00/13] Go closures, libffi, and the static chain
- Re: [PATCH 00/13] Go closures, libffi, and the static chain
- Re: [gofrontend-dev] Re: [PATCH 00/13] Go closures, libffi, and the static chain
- Re: [gofrontend-dev] Re: [PATCH 00/13] Go closures, libffi, and the static chain