public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] MIPS gas: NewABI option sections
@ 2002-05-11  2:23 Thiemo Seufer
  2002-05-14 15:58 ` Eric Christopher
  0 siblings, 1 reply; 2+ messages in thread
From: Thiemo Seufer @ 2002-05-11  2:23 UTC (permalink / raw)
  To: binutils

Hi All,

this patch lets gas use .reginfo instead of .MIPS.options for n32 ABI.
This is the same way IRIX does.


Thiemo


2002-05-11  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>

	/gas/ChangeLog
	* config/tc-mips.c (md_begin): Fix .reginfo and .MIPS.option section
	alignment for NewABI. Let n32 use .reginfo. Remove useless casts.
	(mips_elf_final_processing): Let n32 use .reginfo.


diff -BurpNX /bigdisk/src/binutils-exclude source-orig/gas/config/tc-mips.c source/gas/config/tc-mips.c
--- source-orig/gas/config/tc-mips.c	Wed Apr 10 18:40:57 2002
+++ source/gas/config/tc-mips.c	Fri May 10 21:22:46 2002
@@ -1379,12 +1401,12 @@ md_begin ()
 	if (strcmp (TARGET_OS, "elf") != 0)
 	  flags |= SEC_ALLOC | SEC_LOAD;
 
-	if (! HAVE_NEWABI)
+	if (file_mips_abi != N64_ABI)
 	  {
 	    sec = subseg_new (".reginfo", (subsegT) 0);
 
-	    (void) bfd_set_section_flags (stdoutput, sec, flags);
-	    (void) bfd_set_section_alignment (stdoutput, sec, 2);
+	    bfd_set_section_flags (stdoutput, sec, flags);
+	    bfd_set_section_alignment (stdoutput, sec, HAVE_NEWABI ? 3 : 2);
 
 #ifdef OBJ_ELF
 	    mips_regmask_frag = frag_more (sizeof (Elf32_External_RegInfo));
@@ -1395,8 +1417,8 @@ md_begin ()
 	    /* The 64-bit ABI uses a .MIPS.options section rather than
                .reginfo section.  */
 	    sec = subseg_new (".MIPS.options", (subsegT) 0);
-	    (void) bfd_set_section_flags (stdoutput, sec, flags);
-	    (void) bfd_set_section_alignment (stdoutput, sec, 3);
+	    bfd_set_section_flags (stdoutput, sec, flags);
+	    bfd_set_section_alignment (stdoutput, sec, 3);
 
 #ifdef OBJ_ELF
 	    /* Set up the option header.  */
@@ -12752,7 +13040,7 @@ void
 mips_elf_final_processing ()
 {
   /* Write out the register information.  */
-  if (! HAVE_NEWABI)
+  if (file_mips_abi != N64_ABI)
     {
       Elf32_RegInfo s;
 

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] MIPS gas: NewABI option sections
  2002-05-11  2:23 [PATCH] MIPS gas: NewABI option sections Thiemo Seufer
@ 2002-05-14 15:58 ` Eric Christopher
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Christopher @ 2002-05-14 15:58 UTC (permalink / raw)
  To: Thiemo Seufer; +Cc: binutils


> 
> 2002-05-11  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
> 
> 	/gas/ChangeLog
> 	* config/tc-mips.c (md_begin): Fix .reginfo and .MIPS.option section
> 	alignment for NewABI. Let n32 use .reginfo. Remove useless casts.
> 	(mips_elf_final_processing): Let n32 use .reginfo.
> 
> 

OK.

-eric

-- 
I will not carve gods

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-05-14 22:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-05-11  2:23 [PATCH] MIPS gas: NewABI option sections Thiemo Seufer
2002-05-14 15:58 ` Eric Christopher

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).