[Bug tree-optimization/43629] [4.3/4.4/4.5 Regression] Struct to register optimization fails

2010-04-02 Thread rguenth at gcc dot gnu dot org


--- Comment #3 from rguenth at gcc dot gnu dot org  2010-04-02 12:50 ---
Really a CCP bug.

int flag;
extern void abort (void);
int main()
{
  int x;
  if (flag)
x = -1;
  else
x = 0xff;
  if (x  ~0xff)
abort ();
  return 0;
}


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

Summary|[4.3/4.4 Regression] Struct |[4.3/4.4/4.5 Regression]
   |to register optimization|Struct to register
   |fails   |optimization fails


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



[Bug tree-optimization/43629] [4.3/4.4/4.5 Regression] Struct to register optimization fails

2010-04-02 Thread julien dot etienne at gmail dot com


--- Comment #4 from julien dot etienne at gmail dot com  2010-04-02 15:03 
---
What about using -O1 -fno-tree-ccp as a workaround rather than -O1
-fno-tree-rsa ?
Isn't it more efficient and more related to the root cause ?

Thanks for your help.

FYI: I was unable to check out the trunk due to firewall restriction (even on
http). I will try it from another connection.


-- 


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



[Bug tree-optimization/43629] [4.3/4.4/4.5 Regression] Struct to register optimization fails

2010-04-02 Thread rguenther at suse dot de


--- Comment #5 from rguenther at suse dot de  2010-04-02 15:04 ---
Subject: Re:  [4.3/4.4/4.5 Regression] Struct
 to register optimization fails

On Fri, 2 Apr 2010, julien dot etienne at gmail dot com wrote:

 --- Comment #4 from julien dot etienne at gmail dot com  2010-04-02 15:03 
 ---
 What about using -O1 -fno-tree-ccp as a workaround rather than -O1
 -fno-tree-rsa ?
 Isn't it more efficient and more related to the root cause ?
 
 Thanks for your help.
 
 FYI: I was unable to check out the trunk due to firewall restriction (even on
 http). I will try it from another connection.

Disabling constant propagation is going to affect code quality a lot
more (and might uncover latent bugs).  Anyway, I have a patch for
trunk already.


-- 


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



[Bug tree-optimization/43629] [4.3/4.4/4.5 Regression] Struct to register optimization fails

2010-04-02 Thread rguenth at gcc dot gnu dot org


--- Comment #6 from rguenth at gcc dot gnu dot org  2010-04-02 16:50 ---
Subject: Bug 43629

Author: rguenth
Date: Fri Apr  2 16:50:04 2010
New Revision: 157944

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=157944
Log:
2010-04-02  Richard Guenther  rguent...@suse.de

PR tree-optimization/43629
* tree-ssa-ccp.c (likely_value): Reset all_undefined_operands
if we have seen a constant value.

* gcc.c-torture/execute/pr43629.c: New testcase.

Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr43629.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-ccp.c


-- 


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