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 middle-end/34241] ICE in forward_propagate_into_cond



------- Comment #3 from rguenth at gcc dot gnu dot org  2007-11-27 13:12 -------
I have a patch.  The expected result is to optimize

<bb 2>:
  a.1_1 = (struct A *) &a;
  <<<change_dynamic_type (struct A *) a.1_1)>>>
  D.1744_2 = a.1_1;
  iftmp.0_3 = (struct A *) D.1744_2;
  if (iftmp.0_3 != 0B)
    goto <bb 3>;
  else
    goto <bb 4>;

<bb 3>:
  D.1746_4 = 1.0e+0;
  __comp_ctor  (iftmp.0_3, 42, 1.0e+0);

<bb 4>:
  return;

to

<bb 2>:
  a.1_1 = (struct A *) &a;
  <<<change_dynamic_type (struct A *) a.1_1)>>>
  iftmp.0_3 = (struct A *) &a;
  D.1746_4 = 1.0e+0;
  __comp_ctor  (iftmp.0_3, 42, 1.0e+0);
  return;


-- 


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


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