re PR rtl-optimization/45728 (ICE: in gen_lowpart_general, at rtlhooks.c:59 at -O1...
authorJakub Jelinek <jakub@redhat.com>
Mon, 20 Sep 2010 20:41:08 +0000 (22:41 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Mon, 20 Sep 2010 20:41:08 +0000 (22:41 +0200)
commit220c5f0c7f75f556a37f0b8ae25c1f5a3a69240f
treefd6859a437a2904175c94cfdd0e4b0b0a34c9f46
parent0a7a6af67e6311a427052ef6fc21f6df72be7b51
re PR rtl-optimization/45728 (ICE: in gen_lowpart_general, at rtlhooks.c:59 at -O1 when comparing union members)

PR rtl-optimization/45728
* expr.c (expand_expr_real_1): If op0 isn't REG or MEM, try
gen_lowpart_common first and if that fails, force_reg first
before calling gen_lowpart.

* gcc.c-torture/compile/pr45728.c: New test.

From-SVN: r164456
gcc/ChangeLog
gcc/expr.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr45728.c [new file with mode: 0644]