This is the mail archive of the
mailing list for the GCC project.
Re: libgo patch committed: Implement reflect.MakeFunc for 386
- From: Ian Lance Taylor <iant at google dot com>
- To: Rainer Orth <ro at cebitec dot uni-bielefeld dot de>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>, "gofrontend-dev at googlegroups dot com" <gofrontend-dev at googlegroups dot com>
- Date: Mon, 30 Sep 2013 06:44:49 -0700
- Subject: Re: libgo patch committed: Implement reflect.MakeFunc for 386
- Authentication-results: sourceware.org; auth=none
- References: <mcrvc1mx822 dot fsf at iant-glaptop dot roam dot corp dot google dot com> <ydd4n92bgq0 dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE>
On Mon, Sep 30, 2013 at 6:07 AM, Rainer Orth
> Ian Lance Taylor <email@example.com> writes:
>> Following up on my earlier patch, this patch implements the
>> reflect.MakeFunc function for 386.
>> Tom Tromey pointed out to me that the libffi closure support can
>> probably be used for this. I was not aware of that support. It
>> supports a lot more processors, and I should probably start using it.
>> The approach I am using does have a couple of advantages: it's more
>> efficient, and it doesn't require any type of writable executable
>> memory. I can get away with that because indirect calls in Go always
>> pass a closure value. So even when and if I do change to using libffi,
>> I might still keep this code for amd64 and 386.
> Unfortunately, this patch (and undoubtedly the corresponding amd64 one)
> break Solaris/x86 libgo bootstrap with native as:
Unfortunately I think I'll have to somehow disable this functionality
on systems with assemblers that do not understand the .cfi directives,
as otherwise calling panic in a function created with MakeFunc will