From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Marius Vollmer Newsgroups: gmane.lisp.guile.devel Subject: Re: gcc optimisation breaks guile floating point Date: 28 Aug 2002 22:26:12 +0200 Sender: guile-devel-admin@gnu.org Message-ID: <8765xuzq57.fsf@zagadka.ping.de> References: <200208272110.OAA20247@onyx.he.net> <15723.64888.759743.439428@blauw.xs4all.nl> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1030566683 14001 127.0.0.1 (28 Aug 2002 20:31:23 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 28 Aug 2002 20:31:23 +0000 (UTC) Cc: Gary Houston , guile-devel@gnu.org Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 17k9TB-0003dN-00 for ; Wed, 28 Aug 2002 22:31:18 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 17k9UV-0003E9-00; Wed, 28 Aug 2002 16:32:39 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 17k9To-00034R-00 for guile-devel@gnu.org; Wed, 28 Aug 2002 16:31:56 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 17k9Tm-00034D-00 for guile-devel@gnu.org; Wed, 28 Aug 2002 16:31:55 -0400 Original-Received: from dialin.speedway42.dip162.dokom.de ([195.138.42.162] helo=zagadka.ping.de) by monty-python.gnu.org with smtp (Exim 4.10) id 17k9Tl-00033Q-00 for guile-devel@gnu.org; Wed, 28 Aug 2002 16:31:53 -0400 Original-Received: (qmail 18128 invoked by uid 1000); 28 Aug 2002 20:26:13 -0000 Original-To: hanwen@cs.uu.nl In-Reply-To: <15723.64888.759743.439428@blauw.xs4all.nl> Original-Lines: 31 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Errors-To: guile-devel-admin@gnu.org X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Developers list for Guile, the GNU extensibility library List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.lisp.guile.devel:1179 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.devel:1179 Han-Wen Nienhuys writes: > I think that these double (as in twice) initializations are weird, and > should go. Why not > > scm_t_double bla; > bla.tag = scm_double_tag > bla.pad = 0x0 > bla.double = z; > return scm_double_cell ( > ((scm_t_double_cell*) &bla) -> car, > ((scm_t_double_cell*) &bla) -> cbr, > ((scm_t_double_cell*) &bla) -> ccr, > ((scm_t_double_cell*) &bla) -> cdr); This looks wierd as well, don't you think? > Another option > > *((unsigned long *) z) = 0; > scm_remember ((SCM) z); > *((double *) z) = x; > return z; I like this better (with a suitable comment of course). I guess that the funny aliasing behaviour applies only to pointers to floating point types, right? -- GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405 _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://mail.gnu.org/mailman/listinfo/guile-devel