* PATCH: Support note section
@ 2003-07-25 23:29 H. J. Lu
2003-07-29 1:15 ` Alan Modra
0 siblings, 1 reply; 2+ messages in thread
From: H. J. Lu @ 2003-07-25 23:29 UTC (permalink / raw)
To: binutils
[-- Attachment #1: Type: text/plain, Size: 110 bytes --]
Now we don't use section name for section type. We can have
.section .foo,"","note"
Here is a patch.
H.J.
[-- Attachment #2: gas-note-2.patch --]
[-- Type: text/plain, Size: 1579 bytes --]
gas/
2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
* config/obj-elf.c (obj_elf_section_type): Also accept "note".
gas/testsuite/
2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
* gas/elf/elf.exp: Add section3 for note section.
* gas/elf/section3.d: New file.
* gas/elf/section3.s: Likewise.
--- gas/config/obj-elf.c.note 2003-05-03 09:09:47.000000000 -0700
+++ gas/config/obj-elf.c 2003-05-21 10:06:57.000000000 -0700
@@ -890,6 +890,8 @@ obj_elf_section_type (str, len)
return SHT_PROGBITS;
if (len == 6 && strncmp (str, "nobits", 6) == 0)
return SHT_NOBITS;
+ if (len == 4 && strncmp (str, "note", 4) == 0)
+ return SHT_NOTE;
#ifdef md_elf_section_type
{
--- gas/testsuite/gas/elf/elf.exp.note 2003-05-04 17:46:57.000000000 -0700
+++ gas/testsuite/gas/elf/elf.exp 2003-05-21 09:59:10.000000000 -0700
@@ -54,6 +54,7 @@ if { ([istarget "*-*-elf*"]
run_dump_test "section0"
run_dump_test "section1"
run_list_test "section2" "$target_machine" "-al" ""
+ run_dump_test "section3"
run_dump_test "symver"
run_list_test "type" "" "" "| grep \"1 \\\[FONT\\\]\""
}
--- gas/testsuite/gas/elf/section3.d.note 2003-05-21 10:24:06.000000000 -0700
+++ gas/testsuite/gas/elf/section3.d 2003-05-21 10:23:17.000000000 -0700
@@ -0,0 +1,6 @@
+#readelf: -S
+#name: note section
+
+#...
+[ ]*\[.*\][ ]+\.foo[ ]+NOTE.*
+#pass
--- gas/testsuite/gas/elf/section3.s.note 2003-05-21 10:24:09.000000000 -0700
+++ gas/testsuite/gas/elf/section3.s 2003-05-21 10:13:13.000000000 -0700
@@ -0,0 +1,2 @@
+ .section .foo,"","note"
+ .byte 0,0,0,0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: PATCH: Support note section
2003-07-25 23:29 PATCH: Support note section H. J. Lu
@ 2003-07-29 1:15 ` Alan Modra
0 siblings, 0 replies; 2+ messages in thread
From: Alan Modra @ 2003-07-29 1:15 UTC (permalink / raw)
To: H. J. Lu; +Cc: binutils
On Fri, Jul 25, 2003 at 11:27:11AM -0700, H. J. Lu wrote:
> * config/obj-elf.c (obj_elf_section_type): Also accept "note".
>
> * gas/elf/elf.exp: Add section3 for note section.
>
> * gas/elf/section3.d: New file.
> * gas/elf/section3.s: Likewise.
OK.
--
Alan Modra
IBM OzLabs - Linux Technology Centre
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-07-29 1:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-25 23:29 PATCH: Support note section H. J. Lu
2003-07-29 1:15 ` Alan Modra
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).