cfgexpand.c (expand_debug_expr): Remove overzealous assertion and useless code.
* cfgexpand.c (expand_debug_expr) <INDIRECT_REF>: Remove overzealous assertion and useless code. <TARGET_MEM_REF>: Likewise. From-SVN: r155229
This commit is contained in:
parent
3c0c50279b
commit
4e25ca6b30
|
@ -1,3 +1,9 @@
|
|||
2009-12-14 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* cfgexpand.c (expand_debug_expr) <INDIRECT_REF>: Remove overzealous
|
||||
assertion and useless code.
|
||||
<TARGET_MEM_REF>: Likewise.
|
||||
|
||||
2009-12-14 Alexandre Oliva <aoliva@redhat.com>
|
||||
|
||||
PR debug/41473
|
||||
|
|
|
@ -2186,7 +2186,6 @@ expand_debug_expr (tree exp)
|
|||
int unsignedp = TYPE_UNSIGNED (TREE_TYPE (exp));
|
||||
addr_space_t as;
|
||||
enum machine_mode address_mode;
|
||||
enum machine_mode pointer_mode;
|
||||
|
||||
switch (TREE_CODE_CLASS (TREE_CODE (exp)))
|
||||
{
|
||||
|
@ -2382,17 +2381,15 @@ expand_debug_expr (tree exp)
|
|||
return NULL;
|
||||
|
||||
if (POINTER_TYPE_P (TREE_TYPE (exp)))
|
||||
as = TYPE_ADDR_SPACE (TREE_TYPE (TREE_TYPE (exp)));
|
||||
{
|
||||
as = TYPE_ADDR_SPACE (TREE_TYPE (TREE_TYPE (exp)));
|
||||
address_mode = targetm.addr_space.address_mode (as);
|
||||
}
|
||||
else
|
||||
as = ADDR_SPACE_GENERIC;
|
||||
|
||||
address_mode = targetm.addr_space.address_mode (as);
|
||||
pointer_mode = targetm.addr_space.pointer_mode (as);
|
||||
|
||||
gcc_assert (GET_MODE (op0) == address_mode
|
||||
|| GET_MODE (op0) == pointer_mode
|
||||
|| GET_CODE (op0) == CONST_INT
|
||||
|| GET_CODE (op0) == CONST_DOUBLE);
|
||||
{
|
||||
as = ADDR_SPACE_GENERIC;
|
||||
address_mode = Pmode;
|
||||
}
|
||||
|
||||
if (TREE_CODE (exp) == ALIGN_INDIRECT_REF)
|
||||
{
|
||||
|
@ -2412,19 +2409,11 @@ expand_debug_expr (tree exp)
|
|||
return NULL;
|
||||
|
||||
op0 = expand_debug_expr
|
||||
(tree_mem_ref_addr (build_pointer_type (TREE_TYPE (exp)),
|
||||
exp));
|
||||
(tree_mem_ref_addr (build_pointer_type (TREE_TYPE (exp)), exp));
|
||||
if (!op0)
|
||||
return NULL;
|
||||
|
||||
as = TYPE_ADDR_SPACE (TREE_TYPE (exp));
|
||||
address_mode = targetm.addr_space.address_mode (as);
|
||||
pointer_mode = targetm.addr_space.pointer_mode (as);
|
||||
|
||||
gcc_assert (GET_MODE (op0) == address_mode
|
||||
|| GET_MODE (op0) == pointer_mode
|
||||
|| GET_CODE (op0) == CONST_INT
|
||||
|| GET_CODE (op0) == CONST_DOUBLE);
|
||||
|
||||
op0 = gen_rtx_MEM (mode, op0);
|
||||
|
||||
|
|
Loading…
Reference in New Issue