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]

[PATCH] Fix gcc.target/mips/mips16e-extends.c testcase


Hello All,

the appended patch changes the cksum8 return value to signed char,
this will prompt the compiler to always use the seb instruction in
that place even when the ABI default is unsigned char.

mips-linux and mips-elf default to signed char, but the SVR4 psABI,
IRIX and the MIPS Inc. SDE toolchain default to unsigned char.


Thiemo


2007-04-25  Thiemo Seufer  <ths@mips.com>

	* gcc.target/mips/mips16e-extends.c (cksum8): Change return
	value to signed char.

Index: gcc/testsuite/gcc.target/mips/mips16e-extends.c
===================================================================
--- gcc/testsuite/gcc.target/mips/mips16e-extends.c	(revision 124154)
+++ gcc/testsuite/gcc.target/mips/mips16e-extends.c	(working copy)
@@ -8,7 +8,7 @@
   return l;
 }
 
-char cksum8 (unsigned long n)
+signed char cksum8 (unsigned long n)
 {
   unsigned long l;
   l = validate (n, (n >> 8) + (n & 0xff));


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