public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/39623]  New: Optimizer changes return from htons(uint16)
@ 2009-04-03  8:57 strk at keybit dot net
  2009-04-03  9:02 ` [Bug c++/39623] " strk at keybit dot net
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: strk at keybit dot net @ 2009-04-03  8:57 UTC (permalink / raw)
  To: gcc-bugs

The bug is known to occur with the following versions:
 - gcc version 4.3.2 20081105 (Red Hat 4.3.2-7) (GCC)
 - g++ (Ubuntu 4.3.2-2ubuntu11) 4.3.3 20090111 (prerelease) 

The symptom of the bug is that when you use -O2 htons(short) returns
'unsigned int' (32 bit) rather then the expected 16bit value.
With no optimization it returns the correct 16bit.

I'll attach a testcase.


-- 
           Summary: Optimizer changes return from htons(uint16)
           Product: gcc
           Version: 4.3.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: strk at keybit dot net


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39623


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-04-23 15:37 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-03  8:57 [Bug c++/39623] New: Optimizer changes return from htons(uint16) strk at keybit dot net
2009-04-03  9:02 ` [Bug c++/39623] " strk at keybit dot net
2009-04-03  9:23 ` schwab at linux-m68k dot org
2009-04-03  9:27 ` strk at keybit dot net
2009-04-22 15:53 ` sje at gcc dot gnu dot org
2009-04-23 15:37 ` sje at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).