From d3cfff61d7aadc3b4f2e185f248db2a4c1a69e3f Mon Sep 17 00:00:00 2001 From: Nathan Sidwell Date: Wed, 19 Dec 2007 10:22:02 +0000 Subject: [PATCH] * ld-elf/seg.t: New. * ld-elf/seg.d: New. * ld-elf/seg.s: New. --- ld/testsuite/ChangeLog | 6 ++++++ ld/testsuite/ld-elf/seg.d | 14 ++++++++++++++ ld/testsuite/ld-elf/seg.s | 6 ++++++ ld/testsuite/ld-elf/seg.t | 16 ++++++++++++++++ 4 files changed, 42 insertions(+) create mode 100644 ld/testsuite/ld-elf/seg.d create mode 100644 ld/testsuite/ld-elf/seg.s create mode 100644 ld/testsuite/ld-elf/seg.t diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog index 3098e083519..3e239163839 100644 --- a/ld/testsuite/ChangeLog +++ b/ld/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2007-12-19 Nathan Sidwell + + * ld-elf/seg.t: New. + * ld-elf/seg.d: New. + * ld-elf/seg.s: New. + 2007-12-15 Alan Modra * ld-scripts/rgn-over.exp: Add --no-overlays for spu. diff --git a/ld/testsuite/ld-elf/seg.d b/ld/testsuite/ld-elf/seg.d new file mode 100644 index 00000000000..ff2c7f9ac8c --- /dev/null +++ b/ld/testsuite/ld-elf/seg.d @@ -0,0 +1,14 @@ +#source: seg.s +#ld: -T seg.t -z max-page-size=0x1000 +#readelf: -l --wide + +#... +Program Headers: + Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align + LOAD .* + LOAD 0x0*001000 0xf*fffff000 0xf*fffff000 0x01000 0x01000 .* + + Section to Segment mapping: + Segment Sections... + 00 .* + 01 reset boot diff --git a/ld/testsuite/ld-elf/seg.s b/ld/testsuite/ld-elf/seg.s new file mode 100644 index 00000000000..24ec5676ff8 --- /dev/null +++ b/ld/testsuite/ld-elf/seg.s @@ -0,0 +1,6 @@ + .section boot,"ax" + .4byte 0x76543210 + .section reset,"ax" + .4byte 0xfedcba98 + .text + .4byte 0x12345678 diff --git a/ld/testsuite/ld-elf/seg.t b/ld/testsuite/ld-elf/seg.t new file mode 100644 index 00000000000..2f86acf18ff --- /dev/null +++ b/ld/testsuite/ld-elf/seg.t @@ -0,0 +1,16 @@ + +SECTIONS +{ + reset - 4 : + { + *(reset) + } + boot - 0x1000 : + { + *(boot) + } = 0xffff + . = + SIZEOF_HEADERS; + .text : { *(.text) } + .data : { *(.data) } + .bss : { *(.bss) } +} -- 2.30.2