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]

minor fix for expand_mult_highpart



This was causing CONST_DOUBLE to be passed to movsi, which could
confuse it.  It is being worked around in the rs6000 backend, and has
been for many years, and will still have to be because of bugs
elsewhere, but at least we can fix this one.

Passed bootstrap & make check on powerpc-linux.

OK to commit?

-- 
- Geoffrey Keating <geoffk@cygnus.com>

===File ~/patches/cygnus/rs6000-widermode.patch=============
2000-07-02  Geoff Keating  <geoffk@cygnus.com>

	* expmed.c (expand_mult_highpart): Use op1 instead of wide_op1 when
	mode instead of wider_mode is being used.

Index: expmed.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/expmed.c,v
retrieving revision 1.60
diff -p -u -c -r1.60 expmed.c
cvs server: conflicting specifications of output style
*** expmed.c	2000/06/24 19:26:42	1.60
--- expmed.c	2000/07/02 19:42:58
*************** expand_mult_highpart (mode, op0, cnst1, 
*** 2785,2791 ****
      {
        mul_highpart_optab = unsignedp ? umul_highpart_optab : smul_highpart_optab;
        target = expand_binop (mode, mul_highpart_optab,
! 			     op0, wide_op1, target, unsignedp, OPTAB_DIRECT);
        if (target)
  	return target;
      }
--- 2785,2791 ----
      {
        mul_highpart_optab = unsignedp ? umul_highpart_optab : smul_highpart_optab;
        target = expand_binop (mode, mul_highpart_optab,
! 			     op0, op1, target, unsignedp, OPTAB_DIRECT);
        if (target)
  	return target;
      }
*************** expand_mult_highpart (mode, op0, cnst1, 
*** 2796,2802 ****
      {
        mul_highpart_optab = unsignedp ? smul_highpart_optab : umul_highpart_optab;
        target = expand_binop (mode, mul_highpart_optab,
! 			     op0, wide_op1, target, unsignedp, OPTAB_DIRECT);
        if (target)
  	/* We used the wrong signedness.  Adjust the result.  */
  	return expand_mult_highpart_adjust (mode, target, op0,
--- 2796,2802 ----
      {
        mul_highpart_optab = unsignedp ? smul_highpart_optab : umul_highpart_optab;
        target = expand_binop (mode, mul_highpart_optab,
! 			     op0, op1, target, unsignedp, OPTAB_DIRECT);
        if (target)
  	/* We used the wrong signedness.  Adjust the result.  */
  	return expand_mult_highpart_adjust (mode, target, op0,
============================================================

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