This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [cft] emit_group_load/store fallout


On Wed, Oct 27, 2004 at 10:18:19AM -0700, Richard Henderson wrote:
> >From the ppc test case in 18163, it looks like things worked 
> before in the cases of a memory destination.  Which is fine
> because we pretty much can do anything we want frobbing the
> mode of memory -- unlike with registers.
> 
> Try this.

Yeah it does.

Would it be ok to (a) commit it (b) add a comment to the effect.

	* expr.c (emit_group_store): Allow mode changes of memory in
	parallels.
	(emit_group_load): Same.

Index: expr.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/expr.c,v
retrieving revision 1.736
diff -c -p -r1.736 expr.c
*** expr.c	26 Oct 2004 23:17:57 -0000	1.736
--- expr.c	27 Oct 2004 17:39:27 -0000
*************** emit_group_load (rtx dst, rtx orig_src, 
*** 1571,1577 ****
  
    gcc_assert (GET_CODE (dst) == PARALLEL);
  
!   if (!SCALAR_INT_MODE_P (m) && m != BLKmode)
      {
        enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_src));
        if (imode == BLKmode)
--- 1571,1579 ----
  
    gcc_assert (GET_CODE (dst) == PARALLEL);
  
!   if (!SCALAR_INT_MODE_P (m)
!       /* We can frob the mode of a memory, but not of a register.  */
!       && !MEM_P (orig_src))
      {
        enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_src));
        if (imode == BLKmode)
*************** emit_group_store (rtx orig_dst, rtx src,
*** 1745,1751 ****
  
    gcc_assert (GET_CODE (src) == PARALLEL);
  
!   if (!SCALAR_INT_MODE_P (m) && m != BLKmode)
      {
        enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_dst));
        if (imode == BLKmode)
--- 1747,1755 ----
  
    gcc_assert (GET_CODE (src) == PARALLEL);
  
!   if (!SCALAR_INT_MODE_P (m)
!       /* We can frob the mode of a memory, but not of a register.  */
!       && !MEM_P (orig_dst))
      {
        enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_dst));
        if (imode == BLKmode)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]