* [Bug optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
@ 2004-02-29 17:17 ` pinskia at gcc dot gnu dot org
2004-05-31 1:57 ` [Bug rtl-optimization/14347] " pinskia at gcc dot gnu dot org
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-02-29 17:17 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-02-29 17:17 -------
Confirmed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |pessimizes-code
Last reconfirmed|0000-00-00 00:00:00 |2004-02-29 17:17:42
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
2004-02-29 17:17 ` [Bug optimization/14347] " pinskia at gcc dot gnu dot org
@ 2004-05-31 1:57 ` pinskia at gcc dot gnu dot org
2004-05-31 17:55 ` ak at muc dot de
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-05-31 1:57 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-05-30 03:48 -------
This has been fixed since 3.3.3, note that -march=pentium3 is needed to get the cmov instruction.
This is what I get in 3.3.3, 3.4.0, and 3.5.0 for the first function:
f:
cmpl $1, 4(%esp)
movl $2, %edx
cmovne foo, %edx
movl %edx, foo
ret
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
Target Milestone|--- |3.3.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
2004-02-29 17:17 ` [Bug optimization/14347] " pinskia at gcc dot gnu dot org
2004-05-31 1:57 ` [Bug rtl-optimization/14347] " pinskia at gcc dot gnu dot org
@ 2004-05-31 17:55 ` ak at muc dot de
2004-05-31 18:13 ` pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: ak at muc dot de @ 2004-05-31 17:55 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From ak at muc dot de 2004-05-30 16:23 -------
Hi, Andrew.
The example you showed is a conditional load, not a conditional store.
Conditional load has always worked.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
` (2 preceding siblings ...)
2004-05-31 17:55 ` ak at muc dot de
@ 2004-05-31 18:13 ` pinskia at gcc dot gnu dot org
2004-05-31 18:34 ` ak at muc dot de
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-05-31 18:13 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |NEW
Target Milestone|3.3.3 |---
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
` (3 preceding siblings ...)
2004-05-31 18:13 ` pinskia at gcc dot gnu dot org
@ 2004-05-31 18:34 ` ak at muc dot de
2004-05-31 18:48 ` pinskia at gcc dot gnu dot org
2004-05-31 22:19 ` ak at muc dot de
6 siblings, 0 replies; 8+ messages in thread
From: ak at muc dot de @ 2004-05-31 18:34 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From ak at muc dot de 2004-05-30 17:02 -------
Sorry reading this again, you're right.
it looks a bit broken though since it will always dirty the cache line,
which can be much more costly than doing the jump. Not sure if that's a
good way. The original way I propose by doing the CMOV on the target
address would avoid this problem.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
` (4 preceding siblings ...)
2004-05-31 18:34 ` ak at muc dot de
@ 2004-05-31 18:48 ` pinskia at gcc dot gnu dot org
2004-05-31 22:19 ` ak at muc dot de
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-05-31 18:48 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-05-30 18:10 -------
So closing as fixed again.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
Target Milestone|--- |3.3.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug rtl-optimization/14347] ifconvert doesn't generate conditional store on i386
2004-02-29 16:57 [Bug optimization/14347] New: ifconvert doesn't generate conditional store on i386 ak at muc dot de
` (5 preceding siblings ...)
2004-05-31 18:48 ` pinskia at gcc dot gnu dot org
@ 2004-05-31 22:19 ` ak at muc dot de
6 siblings, 0 replies; 8+ messages in thread
From: ak at muc dot de @ 2004-05-31 22:19 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From ak at muc dot de 2004-05-31 12:34 -------
Well, the optimization is clearly bogus since it will unncessarily
dirty cache lines, which can be extremly costly. It can also require programs
that didn't need volatile before require to add volatile to add SMP races
(that's legal as done by the compiler, but not very nice) But I will open a
separate bug for that.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14347
^ permalink raw reply [flat|nested] 8+ messages in thread