🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.sun
Article #12954

Sun C bug [from info-gcc]

#12954
From: Tom Perrine x426
Date: Mon, 15 May 1989 21:42
29 lines
1291 bytes
I noticed this in gnu.gcc.bug, and thought people would be interested.

    From: !mcgrath@tully.Berkeley.EDU (Roland McGrath)
    Newsgroups: gnu.gcc.bug
    Subject: gcc 1.35 fixunsdfsi doesn't work on Sun 3 (68020)
    Date: 14 May 89 11:49:54 GMT

    There is a bug in the Sun 3 C compiler such that under -O,
    the `__fixunsdfsi' function in gnulib gets done wrong.
    Without -O, it compiles to:

	    link a6, #0
	    movel a6@(8), d0
	    movel a6@(12), d1
	    jsr Fund
	    unlk a6
	    rts

    With -O, it becomes:

	    link a6, #0
	    jsr Fund
	    unlk a6
	    rts

    which doesn't work.

    The bottom line is that unless you compile gnulib without -O, casting a
    double to an unsigned int won't work (it will always come out zero).
Technical Details
Message-ID: <8905152142.AA03449@eltoro.tots.uucp>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!mit-eddie!uw-beaver!rice!sun-spots-request

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!mit-eddie!uw-beaver!rice!sun-spots-request
From: tots!eltoro!tep%suntan.West@sun.com (Tom Perrine x426)
Newsgroups: comp.sys.sun
Subject: Sun C bug [from info-gcc]
Keywords: Software
Message-ID: <8905152142.AA03449@eltoro.tots.uucp>
Date: 15 May 89 21:42:42 GMT
Sender: usenet@rice.edu
Organization: Sun-Spots
Lines: 29
Approved: Sun-Spots@rice.edu
X-Sun-Spots-Digest: Volume 7, Issue 296, message 16 of 19