This is the mail archive of the gcc@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]

MIPS glibc-2.3.2 build failure with gcc-3.4


I'm building glibc-2.3.2 for mips with the gcc-3.4-20040114 snapshot.

I'm getting an error building sigaction.c:
   ../sysdeps/unix/sysv/linux/mips/sigaction.c:83: error: $1 cannot be used in asm here

This code compiles using gcc-3.3.1.

The error is in global_alloc (global.c:355), in code which was added to 
fix PR 13169 (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13169)

I've attached a cutdown version of sigaction.c.

Command line is "mips-gcc -O2 -c sigaction.c".

Suggestions?


--
Michael Eager     eager@mvista.com	408-328-8426	
MontaVista Software, Inc. 1237 E. Arques Ave., Sunnyvale, CA  94085
extern int *__errno_location (void) __attribute__ ((__const__));

int
__libc_sigaction (sig, act, oact)
     int sig;
     int *act;
     int *oact;
{
  int result;
    {
      int kact, koact;
      if (act)
      result = (
	{ 
	  long err; 
	  long result_var = (
	    { 	
	     	long _sys_result; 
		{ 
		  register long __v0 asm("$2"); 
		  register long __a0 asm("$4") = (long) sig; 
		  register long __a1 asm("$5") = (long) act ? (&kact) : ((void *)0); 
		  register long __a2 asm("$6") = (long) oact ? (&koact) : ((void *)0); 
		  register long __a3 asm("$7") = (long) sizeof (int); 
		  __asm__ volatile ( 
			".set\tnoreorder\n\t" 
			"li\t$2, %5\t\t\t# "
			"rt_sigaction" "\n\t" 
			"syscall\n\t" 
			".set\treorder" 
			: "=r" (__v0), "+r" (__a3) 
			: "r" (__a0), "r" (__a1), "r" (__a2), "i" ((4000 + 194)) 
			: "$1", "$3", "$8", "$9", "$10", "$11", "$12", "$13", "$14", "$15", "$24", "$25");
		   err = __a3;
		   _sys_result = __v0;
		   } _sys_result; 
		});
	      if ( ((long) (err)) ) 
		{ ((*__errno_location ()) = ((result_var))); 
		  result_var = -1L; 
	        } result_var; 
	});

 {
   return result;
 }
}
}


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