This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: A new alpha bug
- To: Jason Merrill <jason at cygnus dot com>
- Subject: Re: A new alpha bug
- From: Jim Wilson <wilson at cygnus dot com>
- Date: Tue, 16 Sep 1997 11:19:19 -0700
- cc: hjl at lucon dot org (H.J. Lu), egcs at cygnus dot com, g++ at cygnus dot com
I think this is better:
Wed Aug 13 17:32:38 1997 Jason Merrill <jason@yorick.cygnus.com>
* expr.c (expand_expr, case TARGET_EXPR): Call mark_addressable
again for the slot after we give it RTL.
Actually, this patch is wrong, because you accidentally inserted your hunk of
code at the wrong place. This is why the patch did not work for H.J. Lu.
The idea seems OK though. However, if we are going to do this, then I think we
should add an `else' clause, so as to avoid doing this work when it is not
necessary.
I will add the following patch to the egcs sources after I have verified that
it works.
Tue Sep 16 11:13:46 1997 Jim Wilson <wilson@cygnus.com>
* expr.c (expand_expr): Remove previous incorrect change.
If target and slot has no DECL_RTL, then call mark_addressable
again for the slot after we give it RTL.
Index: expr.c
===================================================================
RCS file: /cvs/cvsfiles/egcs/gcc/expr.c,v
retrieving revision 1.8
diff -p -r1.8 expr.c
*** expr.c 1997/09/16 07:53:51 1.8
--- expr.c 1997/09/16 18:13:23
*************** expand_expr (exp, target, tmode, modifie
*** 6919,6929 ****
/* All temp slots at this level must not conflict. */
preserve_temp_slots (target);
DECL_RTL (slot) = target;
- if (TREE_ADDRESSABLE (slot))
- {
- TREE_ADDRESSABLE (slot) = 0;
- mark_addressable (slot);
- }
/* Since SLOT is not known to the called function
to belong to its stack frame, we must build an explicit
--- 6919,6924 ----
*************** expand_expr (exp, target, tmode, modifie
*** 6955,6962 ****
if (TREE_OPERAND (exp, 1) == NULL_TREE)
return target;
}
!
! DECL_RTL (slot) = target;
}
exp1 = TREE_OPERAND (exp, 3) = TREE_OPERAND (exp, 1);
--- 6950,6966 ----
if (TREE_OPERAND (exp, 1) == NULL_TREE)
return target;
}
! else
! {
! DECL_RTL (slot) = target;
! /* If we must have an addressable slot, then make sure that
! the RTL that we just stored in slot is OK. */
! if (TREE_ADDRESSABLE (slot))
! {
! TREE_ADDRESSABLE (slot) = 0;
! mark_addressable (slot);
! }
! }
}
exp1 = TREE_OPERAND (exp, 3) = TREE_OPERAND (exp, 1);