On Fri, Jan 20, 2012 at 12:39 AM, Ian Lance Taylor <i...@google.com> wrote
>> Attached patch adds -mieee to tests that need full IEEE compliance to >> pass. While working on patch, I have noticed that go-test.exp doesn't >> pass DEFAULT_GOCFLAGS to go_target_compile procedure in expected >> format (so, these simply get ignored). With this issue fixed, we can >> add -mieee to DEFAULT_GOCFLAGS. Tests, compiled through torture >> procedure, expects their special flags in a separate driver file. > > And I just have to repeat that this patch is an ugly ugly hack, since > -mieee should be the default. Perhaps we should investigate having > gcc/go/gospec.c or gcc/go/lang-specs.h somehow add -mieee for those > targets which require it. After trying some other approaches (including adding libgo.spec, similar to java soultion), I think that attached patch is the most straight-forward solution to enable full IEEE compliance to Go language. 2012-01-29 Uros Bizjak <ubiz...@gmail.com> * config/alpha/alpha.c (alpha_option_overrride): Default to full IEEE compliance mode for Go language. Tested on alphaev68-pc-linux-gnu, where it fixes all go testsuite failures that depend of full IEEE compliance. OK for mainline? Uros.
Index: config/alpha/alpha.c =================================================================== --- config/alpha/alpha.c (revision 183675) +++ config/alpha/alpha.c (working copy) @@ -250,6 +250,11 @@ alpha_option_override (void) SUBTARGET_OVERRIDE_OPTIONS; #endif + /* Default to full IEEE compliance mode for Go language. */ + if (strcmp (lang_hooks.name, "GNU Go") == 0 + && !(target_flags_explicit & MASK_IEEE)) + target_flags |= MASK_IEEE; + alpha_fprm = ALPHA_FPRM_NORM; alpha_tp = ALPHA_TP_PROG; alpha_fptm = ALPHA_FPTM_N;