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]

[patch] T3E fixes


Hi,

this fixes a bug in the definition of unaligned_extendhidi_be in alpha.md and
makes HImode division work on unicosmk.

Bootstrapped on alphaev5-cray-unicosmk2.0.5.X.

Bye

Roman

2001-09-14  Roman Lechtchinsky  <rl@cs.tu-berlin.de>

	* config/alpha/alpha.md (unaligned_extendhidi_be): Fix.
	* config/alpha/unicosmk.h (INIT_TARGET_OPTABS): New.

Index: config/alpha/alpha.md
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/alpha/alpha.md,v
retrieving revision 1.150
diff -c -3 -p -r1.150 alpha.md
*** alpha.md	2001/09/11 08:52:37	1.150
--- alpha.md	2001/09/14 11:19:31
*************** fadd,fmul,fcpys,fdiv,fsqrt,misc,mvi,ftoi
*** 1841,1848 ****
     (set (match_dup 6)
  	(ashift:DI (match_dup 4)
  		   (ashift:DI
! 		     (and:DI (match_dup 5) (const_int 7))
! 		     (const_int 8))))
     (set (subreg:DI (match_operand:QI 0 "register_operand" "") 0)
  	(ashiftrt:DI (match_dup 6) (const_int 48)))]
    "WORDS_BIG_ENDIAN"
--- 1841,1850 ----
     (set (match_dup 6)
  	(ashift:DI (match_dup 4)
  		   (ashift:DI
! 		     (and:DI
! 		       (plus:DI (match_dup 5) (const_int 1))
! 		       (const_int 7))
! 		     (const_int 3))))
     (set (subreg:DI (match_operand:QI 0 "register_operand" "") 0)
  	(ashiftrt:DI (match_dup 6) (const_int 48)))]
    "WORDS_BIG_ENDIAN"
Index: config/alpha/unicosmk.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/alpha/unicosmk.h,v
retrieving revision 1.1
diff -c -3 -p -r1.1 unicosmk.h
*** unicosmk.h	2001/09/11 08:52:37	1.1
--- unicosmk.h	2001/09/14 11:19:31
*************** ssib_section ()			\
*** 648,653 ****
--- 648,661 ----
  #define UDIVDI3_LIBCALL	"$uldiv"
  #define DIVDI3_LIBCALL "$sldiv"
  
+ /* This is necessary to prevent gcc from generating calls to __divsi3.  */
+ 
+ #define INIT_TARGET_OPTABS					\
+   do {								\
+     sdiv_optab->handlers[(int) SImode].libfunc = NULL_RTX;	\
+     udiv_optab->handlers[(int) SImode].libfunc = NULL_RTX;	\
+   } while (0)
+ 
  #undef ASM_OUTPUT_SOURCE_LINE
  
  /* We don't need a start file.  */


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