Re: Use static chain and libffi for Go closures

2015-01-19 Thread Ian Lance Taylor
On Sat, Jan 17, 2015 at 10:34 AM, Uros Bizjak wrote: > On Sat, Jan 17, 2015 at 12:19 AM, Ian Lance Taylor wrote: > >>> You should also revert alpha specific change to >>> libgo/go/testing/quick/quick_test.go, please see [1] and [2]. >>> >>> [1] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg00038.

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Ian Lance Taylor
On Mon, Jan 19, 2015 at 2:09 PM, Richard Henderson wrote: > > Fixed thus; applying to mainline after build testing a cross tomips64el-linux. > > Ian, I assume you'll push this upstream? Committed. (It's a little easier for me if I submit patches to the libgo and gcc/go/gofrontend directories.)

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Richard Henderson
On 01/19/2015 02:26 AM, Andreas Schwab wrote: > Ian Lance Taylor writes: > >> @@ -83,7 +83,7 @@ >> #else /* !defined(USE_LIBFFI_CLOSURES) */ >> >> void >> -makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl) >> +makeFuncFFI(const struct __go_func_type *ftyp, void *impl) >> {

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Uros Bizjak
On Mon, Jan 19, 2015 at 7:14 PM, Richard Henderson wrote: >> Attached is a more conservative v2 patch that conditionally enables >> fixup code when FFI_TARGET_HAS_COMPLEX_TYPE is not defined. >> >> Tested on x86_64-linux-gnu {-m32} without regressions. > > I don't think this version should be req

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Richard Henderson
On 01/19/2015 10:11 AM, Uros Bizjak wrote: > Attached is a more conservative v2 patch that conditionally enables > fixup code when FFI_TARGET_HAS_COMPLEX_TYPE is not defined. > > Tested on x86_64-linux-gnu {-m32} without regressions. I don't think this version should be required. For x86, FFI_TA

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Uros Bizjak
On Sat, Jan 17, 2015 at 7:34 PM, Uros Bizjak wrote: > On Sat, Jan 17, 2015 at 12:19 AM, Ian Lance Taylor wrote: > >>> You should also revert alpha specific change to >>> libgo/go/testing/quick/quick_test.go, please see [1] and [2]. >>> >>> [1] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg00038.h

Re: Use static chain and libffi for Go closures

2015-01-19 Thread Andreas Schwab
Ian Lance Taylor writes: > @@ -83,7 +83,7 @@ > #else /* !defined(USE_LIBFFI_CLOSURES) */ > > void > -makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl) > +makeFuncFFI(const struct __go_func_type *ftyp, void *impl) > { >runtime_panicstring ("libgo built without FFI does

Re: Use static chain and libffi for Go closures

2015-01-18 Thread Ian Lance Taylor
On Sat, Jan 17, 2015 at 2:42 PM, Richard Henderson wrote: > > I tested non-support of libffi go closures before applying the patches > for them for ppc, but I guess I busted something in the meantime. > > Please try this. I don't think that will work if configured with --without-libffi. I'm goin

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Richard Henderson
On 01/17/2015 02:07 PM, Andrew Pinski wrote: > On Sat, Jan 17, 2015 at 2:02 PM, Andreas Schwab wrote: >> Andrew Pinski writes: >> >>> On Sat, Jan 17, 2015 at 1:26 PM, Richard Henderson wrote: On 01/17/2015 11:07 AM, Andreas Schwab wrote: > Richard Henderson writes: > >> On 01/1

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Andrew Pinski
On Sat, Jan 17, 2015 at 2:02 PM, Andreas Schwab wrote: > Andrew Pinski writes: > >> On Sat, Jan 17, 2015 at 1:26 PM, Richard Henderson wrote: >>> On 01/17/2015 11:07 AM, Andreas Schwab wrote: Richard Henderson writes: > On 01/17/2015 01:52 AM, Andreas Schwab wrote: >> ../../..

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Andreas Schwab
Andrew Pinski writes: > On Sat, Jan 17, 2015 at 1:26 PM, Richard Henderson wrote: >> On 01/17/2015 11:07 AM, Andreas Schwab wrote: >>> Richard Henderson writes: >>> On 01/17/2015 01:52 AM, Andreas Schwab wrote: > ../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type >>

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Andrew Pinski
On Sat, Jan 17, 2015 at 1:26 PM, Richard Henderson wrote: > On 01/17/2015 11:07 AM, Andreas Schwab wrote: >> Richard Henderson writes: >> >>> On 01/17/2015 01:52 AM, Andreas Schwab wrote: ../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type name 'ffi_go_closure'

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Richard Henderson
On 01/17/2015 11:07 AM, Andreas Schwab wrote: > Richard Henderson writes: > >> On 01/17/2015 01:52 AM, Andreas Schwab wrote: >>> ../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type name >>> 'ffi_go_closure' >>> void makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Andreas Schwab
Richard Henderson writes: > On 01/17/2015 01:52 AM, Andreas Schwab wrote: >> ../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type name >> 'ffi_go_closure' >> void makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl) >>

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Richard Henderson
On 01/17/2015 01:52 AM, Andreas Schwab wrote: > ../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type name > 'ffi_go_closure' > void makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl) > ^ > ../../../libgo/go/re

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Uros Bizjak
On Sat, Jan 17, 2015 at 12:19 AM, Ian Lance Taylor wrote: >> You should also revert alpha specific change to >> libgo/go/testing/quick/quick_test.go, please see [1] and [2]. >> >> [1] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg00038.html >> [2] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg000

Re: Use static chain and libffi for Go closures

2015-01-17 Thread Andreas Schwab
../../../libgo/go/reflect/makefunc_ffi_c.c:21:53: error: unknown type name 'ffi_go_closure' void makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl) ^ ../../../libgo/go/reflect/makefunc_ffi_c.c:86:48: error: unknown type name

Re: Use static chain and libffi for Go closures

2015-01-16 Thread Ian Lance Taylor
On Fri, Jan 16, 2015 at 2:22 AM, Uros Bizjak wrote: > > You should also revert alpha specific change to > libgo/go/testing/quick/quick_test.go, please see [1] and [2]. > > [1] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg00038.html > [2] https://gcc.gnu.org/ml/gcc-patches/2013-03/msg00038/foo.pat

Re: Use static chain and libffi for Go closures

2015-01-16 Thread Ian Lance Taylor
On Thu, Jan 15, 2015 at 2:12 PM, Richard Henderson wrote: > > All of this has been posted before. > > I believe the ABI change is something we should have for gcc 5. > > Yes, the libffi merge has been causing problems (on targets that > don't even support libgo, annoyingly), but missing support fo

Re: Use static chain and libffi for Go closures

2015-01-16 Thread Uros Bizjak
Hello! > All of this has been posted before. > > I believe the ABI change is something we should have for gcc 5. > > Yes, the libffi merge has been causing problems (on targets that > don't even support libgo, annoyingly), but missing support for > the new libffi interfaces is easier to remedy in

Use static chain and libffi for Go closures

2015-01-15 Thread Richard Henderson
All of this has been posted before. I believe the ABI change is something we should have for gcc 5. Yes, the libffi merge has been causing problems (on targets that don't even support libgo, annoyingly), but missing support for the new libffi interfaces is easier to remedy in a dot release than t