Message ID | alpine.LNX.2.00.1312031031340.8615@zhemvz.fhfr.qr |
---|---|
State | New |
Headers | show |
On Tue, Dec 3, 2013 at 1:32 AM, Richard Biener <rguenther@suse.de> wrote: > On Tue, 3 Dec 2013, Richard Biener wrote: > >> >> Hi, I'm getting a bootstrap fail with Go with our custom patched >> compiler (it adds that warning): >> >> 09:48 < richi> ../../../libgo/runtime/go-signal.c: In function >> 'runtime_sighandler': >> 09:48 < richi> ../../../libgo/runtime/go-signal.c:221:4: error: call to >> function 'runtime_traceback' without a real prototype >> [-Werror=unprototyped-calls] runtime_traceback (g); >> >> which is because the declaration of runtime_traceback looks like >> >> void runtime_traceback(); >> >> and thus if you call it the compiler doesn't know the number of >> arguments or their types and thus unwanted promotions may apply >> that change calling conventions (for example float -> double). >> In this case the argument is a pointer, so it's probably not >> an issue. Still the above is not a prototype which the patch >> below fixes. >> >> Bootstrap/testing in progress on x86_64-unknown-linux-gnu >> (let's hope this was the only one). > > Hmm, didn't work out (the implementation has no argument). > > Try the following instead. > > 2013-12-03 Richard Biener <rguenther@suse.de> > > libgo/ > * runtime/runtime.h (runtime_traceback): Fix prototype. > * runtime/go-signal.c (runtime_sighandler): Don't pass > excess argument to runtime_traceback. Thanks. Too much C++/Go on my part, I guess. Committed to mainline and 4.8 branch. Ian
Index: libgo/runtime/runtime.h =================================================================== --- libgo/runtime/runtime.h (revision 205623) +++ libgo/runtime/runtime.h (working copy) @@ -453,7 +453,7 @@ enum { }; void runtime_hashinit(void); -void runtime_traceback(); +void runtime_traceback(void); void runtime_tracebackothers(G*); /* Index: libgo/runtime/go-signal.c =================================================================== --- libgo/runtime/go-signal.c (revision 205623) +++ libgo/runtime/go-signal.c (working copy) @@ -218,7 +218,7 @@ runtime_sighandler (int sig, Siginfo *in G *g; g = runtime_g (); - runtime_traceback (g); + runtime_traceback (); runtime_tracebackothers (g); /* The gc library calls runtime_dumpregs here, and provides