diff options
author | Andrew Pinski <pinskia@gmail.com> | 2006-12-15 07:48:10 -0800 |
---|---|---|
committer | Andrew Pinski <pinskia@gcc.gnu.org> | 2006-12-15 07:48:10 -0800 |
commit | b779a874835529f43d70951bd1eca7e057eb317e (patch) | |
tree | b7bdee32908b9644c336d231f2405f9e81d32dbd /gcc/tree-inline.c | |
parent | 5db74c32303e26d80ecf7b0c14a71b0ee6b06b55 (diff) | |
download | gcc-b779a874835529f43d70951bd1eca7e057eb317e.zip gcc-b779a874835529f43d70951bd1eca7e057eb317e.tar.gz gcc-b779a874835529f43d70951bd1eca7e057eb317e.tar.bz2 |
re PR tree-optimization/30140 (inliner produces invalid gimple with promoted types)
2006-12-15 Andrew Pinski <pinski@gmail.com>
PR tree-opt/30140
* tree-inline.c (setup_one_parameter): Gimplify the statement if
the variable is not a gimple register variable.
From-SVN: r119883
Diffstat (limited to 'gcc/tree-inline.c')
-rw-r--r-- | gcc/tree-inline.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c index 4e0913e..39d9f11 100644 --- a/gcc/tree-inline.c +++ b/gcc/tree-inline.c @@ -1106,9 +1106,10 @@ setup_one_parameter (copy_body_data *id, tree p, tree value, tree fn, at the end. Note that is_gimple_cast only checks the outer tree code, not its operand. Thus the explicit check that its operand is a gimple value. */ - if (!is_gimple_val (rhs) + if ((!is_gimple_val (rhs) && (!is_gimple_cast (rhs) || !is_gimple_val (TREE_OPERAND (rhs, 0)))) + || !is_gimple_reg (var)) gimplify_stmt (&init_stmt); /* If VAR represents a zero-sized variable, it's possible that the |