From: Nick Clifton <nickc@redhat.com>
To: Eric Christopher <echristo@redhat.com>
Cc: Brett Porter <porter@adacore.com>,
seufer@csv.ica.uni-stuttgart.de, binutils@sources.redhat.com
Subject: Re: MIPS gas doesn't set SH_FLAG
Date: Tue, 01 Mar 2005 09:47:00 -0000 [thread overview]
Message-ID: <42243CE5.1030504@redhat.com> (raw)
In-Reply-To: <1109639860.16067.9.camel@localhost.localdomain>
[-- Attachment #1: Type: text/plain, Size: 175 bytes --]
Hi Eric, Hi Brett, Hi Thiemo,
> ChangeLogs look good, how about that patch? :)
I could have sworn that I attached the file. Oh well... Here it is again.
Cheers
Nick
[-- Attachment #2: mips.patch --]
[-- Type: text/plain, Size: 2999 bytes --]
Index: bfd/elfxx-mips.c
===================================================================
RCS file: /cvs/src/src/bfd/elfxx-mips.c,v
retrieving revision 1.124
diff -c -3 -p -r1.124 elfxx-mips.c
*** bfd/elfxx-mips.c 23 Feb 2005 11:39:14 -0000 1.124
--- bfd/elfxx-mips.c 28 Feb 2005 17:01:12 -0000
*************** _bfd_mips_elf_fake_sections (bfd *abfd,
*** 4578,4583 ****
--- 4578,4587 ----
name = bfd_get_section_name (abfd, sec);
+ /* If the user has specified any MIPS specific
+ flags then make sure that they are propogated. */
+ hdr->sh_flags |= (sec->flags & (SHF_MASKOS | SHF_MASKPROC));
+
if (strcmp (name, ".liblist") == 0)
{
hdr->sh_type = SHT_MIPS_LIBLIST;
Index: gas/config/tc-mips.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-mips.c,v
retrieving revision 1.287
diff -c -3 -p -r1.287 tc-mips.c
*** gas/config/tc-mips.c 23 Feb 2005 12:28:04 -0000 1.287
--- gas/config/tc-mips.c 28 Feb 2005 17:01:16 -0000
*************** s_change_section (int ignore ATTRIBUTE_U
*** 11385,11398 ****
--- 11385,11401 ----
section_type = get_absolute_expression ();
else
section_type = 0;
+
if (*input_line_pointer++ == ',')
section_flag = get_absolute_expression ();
else
section_flag = 0;
+
if (*input_line_pointer++ == ',')
section_entry_size = get_absolute_expression ();
else
section_entry_size = 0;
+
if (*input_line_pointer++ == ',')
section_alignment = get_absolute_expression ();
else
*************** s_change_section (int ignore ATTRIBUTE_U
*** 11424,11429 ****
--- 11427,11447 ----
#endif /* OBJ_ELF */
}
+ #ifdef OBJ_ELF
+ /* Ensure that any MIPS specific flags in ATTR are passed
+ on to FLAGS. */
+
+ int
+ mips_elf_section_flags (flagword flags, int attr)
+ {
+ /* Strictly speaking we ought to only select those bits in the OS and PROC
+ specific sections of the flags which we know to have defined meanings
+ for the MIPS. But using the masks is easier and will prevent stange
+ bugs when new flags are added but this code is not updated. */
+ return flags | (attr & (SHF_MASKPROC | SHF_MASKOS));
+ }
+ #endif /* OBJ_ELF */
+
void
mips_enable_auto_align (void)
{
Index: gas/config/tc-mips.h
===================================================================
RCS file: /cvs/src/src/gas/config/tc-mips.h,v
retrieving revision 1.35
diff -c -3 -p -r1.35 tc-mips.h
*** gas/config/tc-mips.h 29 Apr 2004 05:14:22 -0000 1.35
--- gas/config/tc-mips.h 28 Feb 2005 17:01:16 -0000
*************** extern unsigned long mips_cprmask[4];
*** 150,155 ****
--- 150,158 ----
#define elf_tc_final_processing mips_elf_final_processing
extern void mips_elf_final_processing (void);
+ #define md_elf_section_flags(FLAGS, ATTR, TYPE) \
+ mips_elf_section_flags ((FLAGS), (ATTR))
+ extern int mips_elf_section_flags (flagword, int);
#endif
extern void md_mips_end (void);
next prev parent reply other threads:[~2005-03-01 9:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-24 1:11 Changing .dynstr to be more C++ friendly? Chris Kirby
2005-02-24 13:15 ` MIPS gas doesn't set SH_FLAG Brett Porter
2005-02-28 19:38 ` Nick Clifton
2005-03-01 1:18 ` Eric Christopher
2005-03-01 9:47 ` Nick Clifton [this message]
2005-03-01 16:38 ` Brett Porter
2005-03-01 17:27 ` Eric Christopher
2005-02-24 13:58 ` Changing .dynstr to be more C++ friendly? Alan Modra
2005-02-24 17:14 ` Chris Kirby
2005-02-24 17:28 ` Daniel Jacobowitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42243CE5.1030504@redhat.com \
--to=nickc@redhat.com \
--cc=binutils@sources.redhat.com \
--cc=echristo@redhat.com \
--cc=porter@adacore.com \
--cc=seufer@csv.ica.uni-stuttgart.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).