This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/19790] equality not noticed when signedness differs.


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-05-04 20:31 -------
We get:
  i_3 = i_6 + 1;
  bar (i_3);
  D.1284_20 = (unsigned int) i_3;
  i.0_25 = D.1284_20 + 0ffffffff;
  D.1241_5 = i.0_25 >> 5;
  D.1242_10 = D.1241_5 * 4;
  D.1243_11 = (int *) D.1242_10;
  D.1244_12 = array_8 + D.1243_11;
  D.1245_13 = *D.1244_12;
  D.1246_14 = (long unsigned int) D.1245_13;
  D.1247_15 = i_6 & 31;
  D.1248_16 = 1 << D.1247_15;
  D.1249_17 = D.1246_14 | D.1248_16;
  D.1250_18 = (int) D.1249_17;
  *D.1244_12 = D.1250_18;


Now, which is semi better in that there is no extra cast but there is still a -1 issue, i.0_25 = (unsigned) 
i_6

-- 


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]