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]

Re: c++ on powerpc-linux internal error



> kwview.moc.cpp:381: output_operand: '%l' operand isn't a label

This should be fixed now; I have committed this patch.

Can you confirm that the code now works?

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

===File ~/patches/cygnus/rs6000-elflow.patch================
2000-03-31  Geoff Keating  <geoffk@cygnus.com>

	* config/rs6000/rs6000.c (print_operand): Don't use %l for 'low
	part', it's already in use.  Use %K instead.  Add a return at the
	end of what is now %K.
	* config/rs6000/rs6000.md (elf_low): Use %K instead of %l. 

Index: config/rs6000/rs6000.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/rs6000/rs6000.c,v
retrieving revision 1.115
retrieving revision 1.116
diff -u -p -r1.115 -r1.116
--- rs6000.c	2000/03/20 23:47:38	1.115
+++ rs6000.c	2000/04/01 01:37:44	1.116
@@ -3325,6 +3325,8 @@ print_operand (file, x, code)
       putc ((DEFAULT_ABI == ABI_SOLARIS) ? '.' : '$', file);
       return;
 
+      /* %a is output_address.  */
+
     case 'A':
       /* If X is a constant integer whose low-order 5 bits are zero,
 	 write 'l'.  Otherwise, write 'r'.  This is a kludge to fix a bug
@@ -3350,6 +3352,9 @@ print_operand (file, x, code)
       putc (((INT_LOWPART(x) & 1) == 0 ? 'r' : 'l'), file);
       return;
 
+      /* %c is output_addr_const if a CONSTANT_ADDRESS_P, otherwise
+	 output_operand.  */
+
     case 'C':
       {
 	enum rtx_code code = GET_CODE (x);
@@ -3496,7 +3501,7 @@ print_operand (file, x, code)
       fprintf (file, HOST_WIDE_INT_PRINT_DEC, ~ INT_LOWPART (x));
       return;
 
-    case 'l':
+    case 'K':
       /* X must be a symbolic constant on ELF.  Write an
 	 expression suitable for an 'addi' that adds in the low 16
 	 bits of the MEM.  */
@@ -3516,7 +3521,10 @@ print_operand (file, x, code)
 	  fputs ("@l", file);
 	  print_operand (file, XEXP (XEXP (x, 0), 1), 0);
 	}
+      return;
 
+      /* %l is output_asm_label.  */
+
     case 'L':
       /* Write second word of DImode or DFmode reference.  Works on register
 	 or non-indexed memory only.  */
@@ -3609,6 +3617,8 @@ print_operand (file, x, code)
 
       fprintf (file, "%d", i);
       return;
+
+      /* %n outputs the negative of its operand.  */
 
     case 'N':
       /* Write the number of elements in the vector times 4.  */
============================================================

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