aboutsummaryrefslogtreecommitdiff
path: root/gcc/cfgexpand.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2010-03-31 10:39:22 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2010-03-31 10:39:22 +0200
commit132b4e82958efd279b88e7e1ef5bce1c28b5a326 (patch)
treee6ddc4d3299010bc0414ed8fd249d8272b485b68 /gcc/cfgexpand.c
parent9db4e878920729209f8d747f8aa089e647dc97ab (diff)
downloadgcc-132b4e82958efd279b88e7e1ef5bce1c28b5a326.zip
gcc-132b4e82958efd279b88e7e1ef5bce1c28b5a326.tar.gz
gcc-132b4e82958efd279b88e7e1ef5bce1c28b5a326.tar.bz2
re PR debug/43557 (ICE with -combine and -g)
PR debug/43557 * cfgexpand.c (expand_debug_expr): Handle VOIDmode mode like BLKmode. * gcc.dg/pr43557-1.c: New test. * gcc.dg/pr43557-2.c: New file. From-SVN: r157852
Diffstat (limited to 'gcc/cfgexpand.c')
-rw-r--r--gcc/cfgexpand.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/cfgexpand.c b/gcc/cfgexpand.c
index a797af9..eeb5c73 100644
--- a/gcc/cfgexpand.c
+++ b/gcc/cfgexpand.c
@@ -2358,7 +2358,8 @@ expand_debug_expr (tree exp)
/* If op0 is not BLKmode, but BLKmode is, adjust_mode
below would ICE. While it is likely a FE bug,
try to be robust here. See PR43166. */
- || mode == BLKmode)
+ || mode == BLKmode
+ || (mode == VOIDmode && GET_MODE (op0) != VOIDmode))
{
gcc_assert (MEM_P (op0));
op0 = adjust_address_nv (op0, mode, 0);