gimplify.c (gimplify_call_expr): Don't set CALL_CANNOT_INLINE_P for functions for which the parameter types are...

* gimplify.c (gimplify_call_expr): Don't set CALL_CANNOT_INLINE_P
	for functions for which the parameter types are unknown.

testsuite/
	* gcc.dg/inline-33.c: New test.

From-SVN: r144801
This commit is contained in:
Adam Nemet 2009-03-12 01:02:16 +00:00 committed by Adam Nemet
parent 22571318a9
commit 498e51cabb
4 changed files with 30 additions and 5 deletions

View file

@ -1,3 +1,8 @@
2009-03-11 Adam Nemet <anemet@caviumnetworks.com>
* gimplify.c (gimplify_call_expr): Don't set CALL_CANNOT_INLINE_P
for functions for which the parameter types are unknown.
2009-03-11 Jakub Jelinek <jakub@redhat.com>
PR target/39137

View file

@ -2355,11 +2355,7 @@ gimplify_call_expr (tree *expr_p, gimple_seq *pre_p, bool want_value)
else if (parms)
p = parms;
else
{
if (nargs != 0)
CALL_CANNOT_INLINE_P (*expr_p) = 1;
p = NULL_TREE;
}
p = NULL_TREE;
for (i = 0; i < nargs && p; i++, p = TREE_CHAIN (p))
;

View file

@ -1,3 +1,7 @@
2009-03-11 Adam Nemet <anemet@caviumnetworks.com>
* gcc.dg/inline-33.c: New test.
2009-03-11 Nathan Froyd <froydnj@codesourcery.com>
* gcc.dg/vect/vect-82.c: Combine dg-do and

View file

@ -0,0 +1,20 @@
/* { dg-do compile } */
/* { dg-options "-O3 -fdump-tree-optimized" } */
int i;
int foo ();
main ()
{
return foo (i);
}
int foo (i)
int i;
{
return bar(i);
}
/* { dg-final { scan-tree-dump-times "bar" 2 "optimized" } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */