mirror of
https://gcc.gnu.org/git/gcc.git
synced 2024-12-14 14:33:40 +08:00
re PR c/8467 (Bug in sibling call optimization)
2002-11-11 Franz Sirl <Franz.Sirl-kernel@lauterbach.com> PR c/8467 * gcc.c-torture/execute/20021111-1.c From-SVN: r59026
This commit is contained in:
parent
e84371652c
commit
303b90b001
@ -1,3 +1,9 @@
|
||||
2002-11-11 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
|
||||
|
||||
PR c/8467
|
||||
* stmt.c (tail_recursion_args): Handle DECL_MODE differing from the
|
||||
mode of DECL_RTL case.
|
||||
|
||||
2002-11-11 Janis Johnson <janis187@us.ibm.com>
|
||||
|
||||
* doc/contrib.texi: Merge in the list from the libstdc++ web pages.
|
||||
|
14
gcc/stmt.c
14
gcc/stmt.c
@ -3311,8 +3311,18 @@ tail_recursion_args (actuals, formals)
|
||||
if (GET_MODE (DECL_RTL (f)) == GET_MODE (argvec[i]))
|
||||
emit_move_insn (DECL_RTL (f), argvec[i]);
|
||||
else
|
||||
convert_move (DECL_RTL (f), argvec[i],
|
||||
TREE_UNSIGNED (TREE_TYPE (TREE_VALUE (a))));
|
||||
{
|
||||
rtx tmp = argvec[i];
|
||||
|
||||
if (DECL_MODE (f) != GET_MODE (DECL_RTL (f)))
|
||||
{
|
||||
tmp = gen_reg_rtx (DECL_MODE (f));
|
||||
convert_move (tmp, argvec[i],
|
||||
TREE_UNSIGNED (TREE_TYPE (TREE_VALUE (a))));
|
||||
}
|
||||
convert_move (DECL_RTL (f), tmp,
|
||||
TREE_UNSIGNED (TREE_TYPE (TREE_VALUE (a))));
|
||||
}
|
||||
}
|
||||
|
||||
free_temp_slots ();
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-11-11 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
|
||||
|
||||
PR c/8467
|
||||
* gcc.c-torture/execute/20021111-1.c
|
||||
|
||||
2002-11-09 Eric Botcazou <ebotcazou@libertysurf.fr>
|
||||
|
||||
PR c/8439
|
||||
|
31
gcc/testsuite/gcc.c-torture/execute/20021111-1.c
Normal file
31
gcc/testsuite/gcc.c-torture/execute/20021111-1.c
Normal file
@ -0,0 +1,31 @@
|
||||
/* Origin: PR c/8467 */
|
||||
|
||||
extern void abort (void);
|
||||
extern void exit (int);
|
||||
|
||||
int aim_callhandler(int sess, int conn, unsigned short family, unsigned short type);
|
||||
|
||||
int aim_callhandler(int sess, int conn, unsigned short family, unsigned short type)
|
||||
{
|
||||
static int i = 0;
|
||||
|
||||
if (!conn)
|
||||
return 0;
|
||||
|
||||
if (type == 0xffff)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (i >= 1)
|
||||
abort ();
|
||||
|
||||
i++;
|
||||
return aim_callhandler(sess, conn, family, (unsigned short) 0xffff);
|
||||
}
|
||||
|
||||
int main (void)
|
||||
{
|
||||
aim_callhandler (0, 1, 0, 0);
|
||||
exit (0);
|
||||
}
|
Loading…
Reference in New Issue
Block a user