https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81206

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2021-08-03
             Status|UNCONFIRMED                 |NEW
           Severity|normal                      |enhancement
     Ever confirmed|0                           |1

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Full testcase:

int a;
int b(int c, int d)
{
  //int c, d;
  if (a)
    d = b(c, d);
  return (1 + c) + d;
}

int b1(int c, int d)
{
 // int c, d;
  int t = (1 + c);
  if (a)
    d = b1(c, d);
  return t + d;
}
Both of these should have a tail recursion but currently b1 only does.

Reply via email to