public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
@ 2003-05-27  6:43 ` dhazeghi@yahoo.com
  2003-05-27 15:13 ` pinskia@physics.uc.edu
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: dhazeghi@yahoo.com @ 2003-05-27  6:43 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From dhazeghi@yahoo.com  2003-05-27 06:27 -------
Hello,

I can confirm that the simplification in question is still occuring on gcc 3.3 branch and mainline 
(20030525).

Dara



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
  2003-05-27  6:43 ` [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division dhazeghi@yahoo.com
@ 2003-05-27 15:13 ` pinskia@physics.uc.edu
  2003-07-14  4:21 ` neroden at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: pinskia@physics.uc.edu @ 2003-05-27 15:13 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


pinskia@physics.uc.edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2003-05-27 15:06:16
               date|                            |


------- Additional Comments From pinskia@physics.uc.edu  2003-05-27 15:06 -------
See Dara's comment, I think this is just a documentation problem though.



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
  2003-05-27  6:43 ` [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division dhazeghi@yahoo.com
  2003-05-27 15:13 ` pinskia@physics.uc.edu
@ 2003-07-14  4:21 ` neroden at gcc dot gnu dot org
  2003-07-16  1:31 ` segher at koffie dot nl
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: neroden at gcc dot gnu dot org @ 2003-07-14  4:21 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From neroden at gcc dot gnu dot org  2003-07-14 04:21 -------
Actually, there's a slightly larger problem; if the result is *implementation-defined*, it probably shouldn't vary depending on optimization level, 
which I believe it currently does.  :-(  Unless it's OK to say "Our implementation defines this to be undefined", which seems rather bogus.


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
                   ` (2 preceding siblings ...)
  2003-07-14  4:21 ` neroden at gcc dot gnu dot org
@ 2003-07-16  1:31 ` segher at koffie dot nl
  2003-07-16  9:52 ` rearnsha at arm dot com
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: segher at koffie dot nl @ 2003-07-16  1:31 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From segher at koffie dot nl  2003-07-16 01:31 -------
Subject: Re:  incorrectly simplifies leftshift followed by signed
 power-of-2 division

> if the result is *implementation-defined*, it probably
> shouldn't vary depending on optimization level

"Implementation" includes the specific set of command-line
options.  See C99 3.10.


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
                   ` (3 preceding siblings ...)
  2003-07-16  1:31 ` segher at koffie dot nl
@ 2003-07-16  9:52 ` rearnsha at arm dot com
  2004-07-22 20:33 ` cvs-commit at gcc dot gnu dot org
  2004-07-22 21:12 ` pinskia at gcc dot gnu dot org
  6 siblings, 0 replies; 7+ messages in thread
From: rearnsha at arm dot com @ 2003-07-16  9:52 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From rearnsha at arm dot com  2003-07-16 09:52 -------
Subject: Re:  incorrectly simplifies leftshift followed by 
 signed power-of-2 division

> > if the result is *implementation-defined*, it probably
> > shouldn't vary depending on optimization level
> 
> "Implementation" includes the specific set of command-line
> options.  See C99 3.10.
> 

Even if I bought that idea (and I don't particularly in this case):

1) We are talking about C90 specified behaviour
2) An implementation still has to document what the behaviour is for each 
option (that's the "defined" bit :-)

What we have at present is -O gives undefined behaviour...

R.


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
                   ` (4 preceding siblings ...)
  2003-07-16  9:52 ` rearnsha at arm dot com
@ 2004-07-22 20:33 ` cvs-commit at gcc dot gnu dot org
  2004-07-22 21:12 ` pinskia at gcc dot gnu dot org
  6 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-07-22 20:33 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-07-22 20:33 -------
Subject: Bug 7284

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	jsm28@gcc.gnu.org	2004-07-22 20:33:34

Modified files:
	gcc            : ChangeLog fold-const.c 
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/execute: pr7284-1.c 

Log message:
	PR c/7284
	* fold-const.c (extract_muldiv_1): Do not treat signed left shift
	as multiplication.
	
	testsuite:
	* gcc.c-torture/execute/pr7284-1.c: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.4642&r2=2.4643
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fold-const.c.diff?cvsroot=gcc&r1=1.428&r2=1.429
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4038&r2=1.4039
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/pr7284-1.c.diff?cvsroot=gcc&r1=NONE&r2=1.1



-- 


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


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

* [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division
       [not found] <20020712042600.7284.algrant@acm.org>
                   ` (5 preceding siblings ...)
  2004-07-22 20:33 ` cvs-commit at gcc dot gnu dot org
@ 2004-07-22 21:12 ` pinskia at gcc dot gnu dot org
  6 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-22 21:12 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-22 21:12 -------
Fixed for 3.5.0.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |3.5.0


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


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

end of thread, other threads:[~2004-07-22 21:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20020712042600.7284.algrant@acm.org>
2003-05-27  6:43 ` [Bug c/7284] incorrectly simplifies leftshift followed by signed power-of-2 division dhazeghi@yahoo.com
2003-05-27 15:13 ` pinskia@physics.uc.edu
2003-07-14  4:21 ` neroden at gcc dot gnu dot org
2003-07-16  1:31 ` segher at koffie dot nl
2003-07-16  9:52 ` rearnsha at arm dot com
2004-07-22 20:33 ` cvs-commit at gcc dot gnu dot org
2004-07-22 21:12 ` pinskia 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).