This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: Add a test for multiple sections with same name


On Fri, May 07, 2004 at 08:39:00AM -0700, H. J. Lu wrote:
> This patch is the same as
> 
> http://sources.redhat.com/ml/binutils/2004-05/msg00022.html
> 
> It is the last patch needed to get multiple sections with same name
> working on ia32, ia64 and x86-64. Can you take a look?
> 
> Thanks.
> 
> 

Here is a testcase for it.


H.J.
---
2004-05-10  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/i386/group-1.d: New file. Test section group.
	* gas/i386/group-1.s: Likewise.

	* gas/i386/i386.exp: Run group-1.

--- gas/testsuite/gas/i386/group-1.d.same	2004-05-10 07:49:36.000000000 -0700
+++ gas/testsuite/gas/i386/group-1.d	2004-05-10 07:54:32.000000000 -0700
@@ -0,0 +1,15 @@
+#objdump: -s
+#name: i386 group 1
+
+.*: +file format .*
+
+Contents of section .text:
+ 0000 76fe                                 v.              
+Contents of section .text:
+ 0000 ebfe                                 ..              
+Contents of section .eh_frame:
+ 0000 02000000 02000000                    ........        
+Contents of section foo:
+ 0000 01000000 04000000                    ........        
+Contents of section bar:
+ 0000 01000000 05000000                    ........        
--- gas/testsuite/gas/i386/group-1.s.same	2004-05-10 07:49:36.000000000 -0700
+++ gas/testsuite/gas/i386/group-1.s	2004-05-10 07:49:36.000000000 -0700
@@ -0,0 +1,13 @@
+	.section	.text,"axG",@progbits,foo,comdat
+.L1:
+.L5:
+	jbe	.L5
+.L2:
+	.section	.text,"axG",@progbits,bar,comdat
+.L3:
+.L6:
+	jmp	.L6
+.L4:
+	.section	.eh_frame,"a",@progbits
+	.long	.L2-.L1
+	.long	.L4-.L3
--- gas/testsuite/gas/i386/i386.exp.same	2004-04-22 08:21:25.000000000 -0700
+++ gas/testsuite/gas/i386/i386.exp	2004-05-10 07:49:36.000000000 -0700
@@ -86,6 +86,7 @@ if [expr ([istarget "i*86-*-*"] ||  [ist
 	run_dump_test "tlsd"
 	run_dump_test "tlspic"
 	run_dump_test "tlsnopic"
+	run_dump_test "group-1"
     }
 
     # This is a PE specific test.


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