Re: gccgo branch and darwin

2010-12-01 Thread Ian Lance Taylor
Arnaud Lacombe writes: > On Fri, Nov 19, 2010 at 11:58 PM, Arnaud Lacombe wrote: >> sysinfo.go:2874:13: error: use of undefined type 'func___sighandler_t' >> > gen-sysinfo.go has : > > // type ___sighandler_t func*(int32) That is not valid Go, so this looks like a bug in godump.c. What does th

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 5:55 PM, Richard Guenther wrote: > On Fri, Nov 19, 2010 at 10:46 PM, Ian Lance Taylor wrote: >> Jack Howarth writes: >> >>> ps Is there a list of targets that the go compiler has been built on? >> >> It's been built and tested on x86 and x86_64 GNU/Linux and RTEMS. >

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 11:58 PM, Arnaud Lacombe wrote: > sysinfo.go:2874:13: error: use of undefined type 'func___sighandler_t' > gen-sysinfo.go has : // type ___sighandler_t func*(int32) It may not like the * as the following: package main import "fmt" type ___sighandler_t func(int32) fu

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 11:58 PM, Arnaud Lacombe wrote: > [...] > continuing to dig for other errors. > One nits; is there any reason to use `__xpg_strerror_r()' which is not POSIX, versus 'strerror_r()' [0] ? // FIXME: The name is only right for glibc. func libc_strerror_r(int, *byte, Size_

Re: gccgo branch and darwin

2010-11-19 Thread Ralf Wildenhues
* Arnaud Lacombe wrote on Sat, Nov 20, 2010 at 05:58:13AM CET: > --- a/libgo/mksysinfo.sh > +++ b/libgo/mksysinfo.sh > @@ -79,7 +79,7 @@ grep '^const _E' gen-sysinfo.go | \ > > # The O_xxx flags. > grep '^const _\(O\|F\|FD\)_' gen-sysinfo.go | \ > - sed -e 's/^\(const \)_\(\(O\|F\|FD\)_[^= ]*\)

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 10:43 PM, Arnaud Lacombe wrote: > ok, this last one is a classic use of non-standard extension of GNU > sed I should be able to fix it. It might not be clean, though. > Here we go, most redefinition fixed by the attached patch. Remaining error are: sysinfo.go:3034:6:

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 10:17 PM, Arnaud Lacombe wrote: > Hi, > > On Fri, Nov 19, 2010 at 2:55 PM, Jack Howarth > wrote: >> Ian, >>   The current gccgo branch (at r166931) fails to bootstrap on >> x86_64-apple-darwin10 >> using... >> >> ../gccgo/configure --prefix=/Users/howarth/dist --wit

Re: gccgo branch and darwin

2010-11-19 Thread Arnaud Lacombe
Hi, On Fri, Nov 19, 2010 at 2:55 PM, Jack Howarth wrote: > Ian, >   The current gccgo branch (at r166931) fails to bootstrap on > x86_64-apple-darwin10 > using... > > ../gccgo/configure --prefix=/Users/howarth/dist --with-gmp=/sw --with-ppl=/sw > --with-cloog=/sw --with-mpc=/sw --with-libiconv-

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Jack Howarth writes: >Actually that wasn't the fix. The change... > void > -__go_scanstacks (void (*scan) (byte *, int64_t)) > +__go_scanstacks (void (*scan) (unsigned char *, int64)) Thanks. Sorry for misunderstanding. I committed the change from int64_t to int64. > /var/tmp//ccVFZHcc

Re: gccgo branch and darwin

2010-11-19 Thread Jack Howarth
On Fri, Nov 19, 2010 at 03:59:40PM -0800, Ian Lance Taylor wrote: > Jack Howarth writes: > > > where you have... > > > > void > > __go_scanstacks (void (*scan) (unsigned char *, int64_t)) > > > > in gccgo/libgo/runtime/go-go.c but... > > > > void__go_scanstacks(void (*scan)(byte *, int64)); >

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Jack Howarth writes: > where you have... > > void > __go_scanstacks (void (*scan) (unsigned char *, int64_t)) > > in gccgo/libgo/runtime/go-go.c but... > > void__go_scanstacks(void (*scan)(byte *, int64)); > > in gccgo/libgo/runtime/runtime.h. Thanks. I don't know why this causes an error o

Re: gccgo branch and darwin

2010-11-19 Thread Jack Howarth
On Fri, Nov 19, 2010 at 01:23:14PM -0800, Ian Lance Taylor wrote: > Jack Howarth writes: > > >Actually, darwin doesn't use the boehm-gc/pthread_stop_world.c containing > > the SIGRTMIN code. There is an entirely separate > > boehm-gc/darwin_stop_world.c > > for the thread handling on darwin.

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Richard Guenther writes: > Huh, I wonder why we have frontends that do not even build for all > primary hosts. Because the perfect is the enemy of the good. > Btw, bugzilla needs a Go and a libgo component. Yes, it's on the list for after the merge, following Joseph Myers's checklist. Thanks

Re: gccgo branch and darwin

2010-11-19 Thread Richard Guenther
On Fri, Nov 19, 2010 at 10:46 PM, Ian Lance Taylor wrote: > Jack Howarth writes: > >> ps Is there a list of targets that the go compiler has been built on? > > It's been built and tested on x86 and x86_64 GNU/Linux and RTEMS. Huh, I wonder why we have frontends that do not even build for all pri

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Jack Howarth writes: > ps Is there a list of targets that the go compiler has been built on? It's been built and tested on x86 and x86_64 GNU/Linux and RTEMS. Ian

Re: gccgo branch and darwin

2010-11-19 Thread Jack Howarth
On Fri, Nov 19, 2010 at 01:23:14PM -0800, Ian Lance Taylor wrote: > Jack Howarth writes: > > >Actually, darwin doesn't use the boehm-gc/pthread_stop_world.c containing > > the SIGRTMIN code. There is an entirely separate > > boehm-gc/darwin_stop_world.c > > for the thread handling on darwin.

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Jack Howarth writes: >Actually, darwin doesn't use the boehm-gc/pthread_stop_world.c containing > the SIGRTMIN code. There is an entirely separate boehm-gc/darwin_stop_world.c > for the thread handling on darwin. While boehm-gc/pthread_stop_world.c is > compiled on darwin, the code in it is s

Re: gccgo branch and darwin

2010-11-19 Thread Jack Howarth
On Fri, Nov 19, 2010 at 12:16:43PM -0800, Ian Lance Taylor wrote: > Jack Howarth writes: > > >The current gccgo branch (at r166931) fails to bootstrap on > > x86_64-apple-darwin10 > > using... > > Thanks for trying it. If you fix that problem, you're going to have > other problems too. >

Re: gccgo branch and darwin

2010-11-19 Thread Ian Lance Taylor
Jack Howarth writes: >The current gccgo branch (at r166931) fails to bootstrap on > x86_64-apple-darwin10 > using... Thanks for trying it. If you fix that problem, you're going to have other problems too. Specifically, I know that it's going to fail to create a .go_export section because

RE: gccgo branch and darwin

2010-11-19 Thread Jack Howarth
Ian, It seems that go-go.c needs to be more portable. This issue apparently was addressed in gcc/boehm-gc/pthread_stop_world.c with... /* * We use signals to stop threads during GC. * * Suspended threads wait in signal handler for SIG_THR_RESTART. * That's more portable than semaphores or c