diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-10-15 06:42:00 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-10-15 06:42:00 +0000 |
commit | 9de5a1fdfa2023fb4886ec08eb8bf7d98a86a828 (patch) | |
tree | e54ba6d87418a5c238d9d857a44d841e06733cc1 /gcc/tree-switch-conversion.c | |
parent | ab5877545606bfe28eb8458a608ca8bee2d68e48 (diff) | |
download | gcc-9de5a1fdfa2023fb4886ec08eb8bf7d98a86a828.tar.gz |
Revert unintended commit.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@141128 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-switch-conversion.c')
-rw-r--r-- | gcc/tree-switch-conversion.c | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/gcc/tree-switch-conversion.c b/gcc/tree-switch-conversion.c index 798cf161569..e9757454f21 100644 --- a/gcc/tree-switch-conversion.c +++ b/gcc/tree-switch-conversion.c @@ -296,29 +296,12 @@ check_final_bb (void) { basic_block bb = gimple_phi_arg_edge (phi, i)->src; - if (bb == info.switch_bb - || (single_pred_p (bb) && single_pred (bb) == info.switch_bb)) + if ((bb == info.switch_bb + || (single_pred_p (bb) && single_pred (bb) == info.switch_bb)) + && !is_gimple_ip_invariant (gimple_phi_arg_def (phi, i))) { - tree reloc, val; - - val = gimple_phi_arg_def (phi, i); - if (!is_gimple_ip_invariant (val)) - { - info.reason = " Non-invariant value from a case\n"; - return false; /* Non-invariant argument. */ - } - reloc = initializer_constant_valid_p (val, TREE_TYPE (val)); - if ((flag_pic && reloc != null_pointer_node) - || (!flag_pic && reloc == NULL_TREE)) - { - if (reloc) - info.reason - = " Value from a case would need runtime relocations\n"; - else - info.reason - = " Value from a case is not a valid initializer\n"; - return false; - } + info.reason = " Non-invariant value from a case\n"; + return false; /* Non-invariant argument. */ } } } |