* Re: [PATCH] x86: .bss/.previous interaction
@ 2005-04-01 7:51 Jan Beulich
0 siblings, 0 replies; 2+ messages in thread
From: Jan Beulich @ 2005-04-01 7:51 UTC (permalink / raw)
To: amodra; +Cc: binutils
Should this also go in the 2.16 branch?
>>> Alan Modra <amodra@bigpond.net.au> 01.04.05 01:29:27 >>>
On Thu, Mar 31, 2005 at 06:00:39PM +0200, Jan Beulich wrote:
> gas/
> 2005-03-31 Jan Beulich <jbeulich@novell.com>
>
> * config/tc-i386.c (s_bss): Call obj_elf_section_change_hook.
>
> gas/testsuite/
> 2005-03-31 Jan Beulich <jbeulich@novell.com>
>
> * gas/i386/bss.[sd]: New.
> * gas/i386/i386.exp: Run new test.
OK.
> +
> +if { ([istarget i*86-*-*] || [istarget x86_64-*-*]) } then {
> + if { [istarget *-*-elf*]
> + || [istarget *-*-linux*]
> + && ![istarget *-*-linux*aout*]
> + && ![istarget *-*-linux*oldld*]
> + } then {
> + run_dump_test "bss"
> + }
> +}
Except that this should just be a one line addition to the existing ELF
tests for i386.
--
Alan Modra
IBM OzLabs - Linux Technology Centre
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH] x86: .bss/.previous interaction
@ 2005-03-31 22:56 Jan Beulich
0 siblings, 0 replies; 2+ messages in thread
From: Jan Beulich @ 2005-03-31 22:56 UTC (permalink / raw)
To: binutils
[-- Attachment #1: Type: text/plain, Size: 2100 bytes --]
i386's and x86-64's .bss did not interact correctly with ELF's .previous.
Built and tested on i686-pc-linux-gnu as well as for i686-coff and i686-aout.
Jan
gas/
2005-03-31 Jan Beulich <jbeulich@novell.com>
* config/tc-i386.c (s_bss): Call obj_elf_section_change_hook.
gas/testsuite/
2005-03-31 Jan Beulich <jbeulich@novell.com>
* gas/i386/bss.[sd]: New.
* gas/i386/i386.exp: Run new test.
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/config/tc-i386.c 2005-03-14 15:08:07.000000000 +0100
+++ 2005-03-31/gas/config/tc-i386.c 2005-03-31 17:19:26.899585544 +0200
@@ -5306,6 +5306,10 @@ s_bss (ignore)
{
int temp;
+#if defined (OBJ_ELF) || defined (OBJ_MAYBE_ELF)
+ if (IS_ELF)
+ obj_elf_section_change_hook ();
+#endif
temp = get_absolute_expression ();
subseg_set (bss_section, (subsegT) temp);
demand_empty_rest_of_line ();
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/bss.d 1970-01-01 01:00:00.000000000 +0100
+++ 2005-03-31/gas/testsuite/gas/i386/bss.d 2005-03-31 16:17:50.000000000 +0200
@@ -0,0 +1,7 @@
+#objdump: -s
+#name: i386 .bss
+
+.*: +file format .*
+
+Contents of section \.other:
+ 0000 0102 .*
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/bss.s 1970-01-01 01:00:00.000000000 +0100
+++ 2005-03-31/gas/testsuite/gas/i386/bss.s 2005-03-31 16:19:26.000000000 +0200
@@ -0,0 +1,7 @@
+ .data
+ .section .other, "a", @progbits
+ .byte 1
+ .bss
+ .skip 1
+ .previous
+ .byte 2
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/i386.exp 2005-03-31 16:25:51.000000000 +0200
+++ 2005-03-31/gas/testsuite/gas/i386/i386.exp 2005-03-31 17:10:14.200608560 +0200
@@ -135,3 +135,13 @@ if [expr ([istarget "i*86-*-*"] || [ista
set ASFLAGS "$old_ASFLAGS"
}
+
+if { ([istarget i*86-*-*] || [istarget x86_64-*-*]) } then {
+ if { [istarget *-*-elf*]
+ || [istarget *-*-linux*]
+ && ![istarget *-*-linux*aout*]
+ && ![istarget *-*-linux*oldld*]
+ } then {
+ run_dump_test "bss"
+ }
+}
[-- Attachment #2: binutils-mainline-x86-elf-bss.patch --]
[-- Type: text/plain, Size: 2030 bytes --]
i386's and x86-64's .bss did not interact correctly with ELF's .previous.
Built and tested on i686-pc-linux-gnu as well as for i686-coff and i686-aout.
Jan
gas/
2005-03-31 Jan Beulich <jbeulich@novell.com>
* config/tc-i386.c (s_bss): Call obj_elf_section_change_hook.
gas/testsuite/
2005-03-31 Jan Beulich <jbeulich@novell.com>
* gas/i386/bss.[sd]: New.
* gas/i386/i386.exp: Run new test.
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/config/tc-i386.c 2005-03-14 15:08:07.000000000 +0100
+++ 2005-03-31/gas/config/tc-i386.c 2005-03-31 17:19:26.899585544 +0200
@@ -5306,6 +5306,10 @@ s_bss (ignore)
{
int temp;
+#if defined (OBJ_ELF) || defined (OBJ_MAYBE_ELF)
+ if (IS_ELF)
+ obj_elf_section_change_hook ();
+#endif
temp = get_absolute_expression ();
subseg_set (bss_section, (subsegT) temp);
demand_empty_rest_of_line ();
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/bss.d 1970-01-01 01:00:00.000000000 +0100
+++ 2005-03-31/gas/testsuite/gas/i386/bss.d 2005-03-31 16:17:50.000000000 +0200
@@ -0,0 +1,7 @@
+#objdump: -s
+#name: i386 .bss
+
+.*: +file format .*
+
+Contents of section \.other:
+ 0000 0102 .*
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/bss.s 1970-01-01 01:00:00.000000000 +0100
+++ 2005-03-31/gas/testsuite/gas/i386/bss.s 2005-03-31 16:19:26.000000000 +0200
@@ -0,0 +1,7 @@
+ .data
+ .section .other, "a", @progbits
+ .byte 1
+ .bss
+ .skip 1
+ .previous
+ .byte 2
--- /home/jbeulich/src/binutils/mainline/2005-03-31/gas/testsuite/gas/i386/i386.exp 2005-03-31 16:25:51.000000000 +0200
+++ 2005-03-31/gas/testsuite/gas/i386/i386.exp 2005-03-31 17:10:14.200608560 +0200
@@ -135,3 +135,13 @@ if [expr ([istarget "i*86-*-*"] || [ista
set ASFLAGS "$old_ASFLAGS"
}
+
+if { ([istarget i*86-*-*] || [istarget x86_64-*-*]) } then {
+ if { [istarget *-*-elf*]
+ || [istarget *-*-linux*]
+ && ![istarget *-*-linux*aout*]
+ && ![istarget *-*-linux*oldld*]
+ } then {
+ run_dump_test "bss"
+ }
+}
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-04-01 7:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-01 7:51 [PATCH] x86: .bss/.previous interaction Jan Beulich
-- strict thread matches above, loose matches on Subject: below --
2005-03-31 22:56 Jan Beulich
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).