aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2007-08-31 14:46:55 +0000
committerNick Clifton <nickc@redhat.com>2007-08-31 14:46:55 +0000
commita1438fce30be2e62cfcb2d798e46766c65b82316 (patch)
tree18bf20f54ee1227ecc79678daa4e6c244dcce638 /ld/testsuite
parent30b0f203ddf59fe5d666562be4a4e4ea7d04fa47 (diff)
downloadgdb-a1438fce30be2e62cfcb2d798e46766c65b82316.zip
gdb-a1438fce30be2e62cfcb2d798e46766c65b82316.tar.gz
gdb-a1438fce30be2e62cfcb2d798e46766c65b82316.tar.bz2
* ldlang.c (lang_map): Increment lang_statement_iteration so that DEFINED() expressions are correctly computed.
* testsuite/ld-script/map-address.d, * testsuite/ld-script/map-address.t: Add a test for testing DEFINED in map output.
Diffstat (limited to 'ld/testsuite')
-rw-r--r--ld/testsuite/ChangeLog6
-rw-r--r--ld/testsuite/ld-scripts/map-address.d2
-rw-r--r--ld/testsuite/ld-scripts/map-address.t2
3 files changed, 10 insertions, 0 deletions
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index ec3cf04..5b0ce32 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+2007-08-31 Tristan Gingold <gingold@adacore.com>
+
+ * ld-script/map-address.t: Add a test for testing DEFINED in map
+ output.
+ * ld-script/map-address.d: Update expected output.
+
2007-08-28 Mark Shinwell <shinwell@codesourcery.com>
Joseph Myers <joseph@codesourcery.com>
diff --git a/ld/testsuite/ld-scripts/map-address.d b/ld/testsuite/ld-scripts/map-address.d
index 289b685..7877ca4 100644
--- a/ld/testsuite/ld-scripts/map-address.d
+++ b/ld/testsuite/ld-scripts/map-address.d
@@ -1,6 +1,8 @@
#...
Linker script and memory map
#...
+ *0x0*000020 *def1 = .*
+ *0x0*000020 *def2 = def1
*0x0*010001 *\. = 0x10001
*0x0*010001 *foo = \.
*0x0*010201 *\. = \(\. \+ 0x200\)
diff --git a/ld/testsuite/ld-scripts/map-address.t b/ld/testsuite/ld-scripts/map-address.t
index 8f2dfeb..e077ed1 100644
--- a/ld/testsuite/ld-scripts/map-address.t
+++ b/ld/testsuite/ld-scripts/map-address.t
@@ -1,5 +1,7 @@
SECTIONS
{
+ def1 = DEFINED(foo) ? 0x10 : 0x20;
+ def2 = def1;
. = 0x10001;
foo = .;
. += 0x200;