libgcc2.h patch breaks c4x target

Michael Hayes m.hayes@elec.canterbury.ac.nz
Thu Sep 21 17:14:00 GMT 2000


The following patch breaks complilation of libgcc2.c for the C4x
target.  Can you please explain what exactly the problem was
that required this patch so that we can come up with a compromise.

Thanks, Michael.

2000-09-10  Stephane Carrez  <Stephane.Carrez@worldnet.fr>

	* libgcc2.h: Use LONG_LONG_TYPE_SIZE instead of MIN_UNITS_PER_WORD
	to decide whether 64-bit support must be generated.

Index: libgcc2.h
===================================================================
RCS file: /cvs/gcc/egcs/gcc/libgcc2.h,v
retrieving revision 1.7
retrieving revision 1.8
diff -c -3 -p -r1.7 -r1.8
*** libgcc2.h	2000/06/11 04:29:47	1.7
--- libgcc2.h	2000/09/10 13:02:52	1.8
*************** typedef unsigned int UHItype	__attribute
*** 90,96 ****
  /* These typedefs are usually forbidden on dsp's with UNITS_PER_WORD 1 */
  typedef 	 int SItype	__attribute__ ((mode (SI)));
  typedef unsigned int USItype	__attribute__ ((mode (SI)));
! #if MIN_UNITS_PER_WORD > 2
  /* These typedefs are usually forbidden on archs with UNITS_PER_WORD 2 */
  typedef		 int DItype	__attribute__ ((mode (DI)));
  typedef unsigned int UDItype	__attribute__ ((mode (DI)));
--- 90,96 ----
  /* These typedefs are usually forbidden on dsp's with UNITS_PER_WORD 1 */
  typedef 	 int SItype	__attribute__ ((mode (SI)));
  typedef unsigned int USItype	__attribute__ ((mode (SI)));
! #if LONG_LONG_TYPE_SIZE > 32
  /* These typedefs are usually forbidden on archs with UNITS_PER_WORD 2 */
  typedef		 int DItype	__attribute__ ((mode (DI)));
  typedef unsigned int UDItype	__attribute__ ((mode (DI)));
*************** typedef int word_type __attribute__ ((mo
*** 163,169 ****
  #define UDWtype	UTItype
  #define __NW(a,b)	__ ## a ## di ## b
  #define __NDW(a,b)	__ ## a ## ti ## b
! #elif MIN_UNITS_PER_WORD > 2
  #define W_TYPE_SIZE (4 * BITS_PER_UNIT)
  #define Wtype	SItype
  #define UWtype	USItype
--- 163,169 ----
  #define UDWtype	UTItype
  #define __NW(a,b)	__ ## a ## di ## b
  #define __NDW(a,b)	__ ## a ## ti ## b
! #elif MIN_UNITS_PER_WORD > 2 || LONG_LONG_TYPE_SIZE > 32
  #define W_TYPE_SIZE (4 * BITS_PER_UNIT)
  #define Wtype	SItype
  #define UWtype	USItype


More information about the Gcc-bugs mailing list