This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH 2/2] ld: Don't evaluate unneeded PROVIDE expressions.
- From: Andrew Burgess <andrew dot burgess at embecosm dot com>
- To: Hans-Peter Nilsson <hans-peter dot nilsson at axis dot com>
- Cc: binutils at sourceware dot org, amodra at gmail dot com
- Date: Tue, 20 Jan 2015 16:08:09 +0000
- Subject: Re: [PATCH 2/2] ld: Don't evaluate unneeded PROVIDE expressions.
- Authentication-results: sourceware.org; auth=none
- References: <20150119110620 dot GB2143 at embecosm dot com> <201501201420 dot t0KEKrhE009072 at ignucius dot se dot axis dot com>
* Hans-Peter Nilsson <hans-peter.nilsson@axis.com> [2015-01-20 15:20:53 +0100]:
> I'd guess the testsuite adjustments were not double-checked that
> they actually do pass on a 32-bit host, as these FAILs are
> introduced by your patches,
I have pushed the patch below that I believe should fix the failures
you are seeing.
Please let me know if you are still seeing any problems.
Sorry for the wasted time, and thanks for bringing this to my
attention.
Andrew
---
Tests that I added in commit c05b575a8dfabab6af5d8586d1a5c0c67f819ac2
fails on 32-bit hosts due to differences in whitespace.
This patch updates the expected output patterns to be more accepting of
differences in whitespace, the tests should now pass.
ld/testsuite/ChangeLog:
* ld-scripts/provide-4-map.d: Update expected output.
* ld-scripts/provide-5-map.d: Likewise.
---
ld/testsuite/ChangeLog | 5 +++++
ld/testsuite/ld-scripts/provide-4-map.d | 18 +++++++++---------
ld/testsuite/ld-scripts/provide-5-map.d | 4 ++--
3 files changed, 16 insertions(+), 11 deletions(-)
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index 0b47494..21cf40e 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2015-01-20 Andrew Burgess <andrew.burgess@embecosm.com>
+ * ld-scripts/provide-4-map.d: Update expected output.
+ * ld-scripts/provide-5-map.d: Likewise.
+
+2015-01-20 Andrew Burgess <andrew.burgess@embecosm.com>
+
* ld-scripts/provide-4.d: New file.
* ld-scripts/provide-4-map.d: New file.
* ld-scripts/provide-4.t: New file.
diff --git a/ld/testsuite/ld-scripts/provide-4-map.d b/ld/testsuite/ld-scripts/provide-4-map.d
index d8e4a28..189d1d0 100644
--- a/ld/testsuite/ld-scripts/provide-4-map.d
+++ b/ld/testsuite/ld-scripts/provide-4-map.d
@@ -1,13 +1,13 @@
#...
Linker script and memory map
#...
- \[!provide\] PROVIDE \(foo, 0x1\)
- \[!provide\] PROVIDE \(bar, 0x2\)
- 0x0+3 PROVIDE \(baz, 0x3\)
-#...
- 0x0+2000 foo
- \[!provide\] PROVIDE \(loc1, ALIGN \(\., 0x10\)\)
- 0x0+2010 PROVIDE \(loc2, ALIGN \(\., 0x10\)\)
- \[!provide\] PROVIDE \(loc3, \(loc1 \+ 0x20\)\)
- 0x0+2030 loc4 = \(loc2 \+ 0x20\)
+ \[!provide\] +PROVIDE \(foo, 0x1\)
+ \[!provide\] +PROVIDE \(bar, 0x2\)
+ 0x0+3 +PROVIDE \(baz, 0x3\)
+#...
+ 0x0+2000 +foo
+ \[!provide\] +PROVIDE \(loc1, ALIGN \(\., 0x10\)\)
+ 0x0+2010 +PROVIDE \(loc2, ALIGN \(\., 0x10\)\)
+ \[!provide\] +PROVIDE \(loc3, \(loc1 \+ 0x20\)\)
+ 0x0+2030 +loc4 = \(loc2 \+ 0x20\)
#...
diff --git a/ld/testsuite/ld-scripts/provide-5-map.d b/ld/testsuite/ld-scripts/provide-5-map.d
index 2271dfd..a75e4aa 100644
--- a/ld/testsuite/ld-scripts/provide-5-map.d
+++ b/ld/testsuite/ld-scripts/provide-5-map.d
@@ -1,6 +1,6 @@
#...
Linker script and memory map
#...
- 0x0+10 foo = 0x10
- \[!provide\] PROVIDE \(foo, bar\)
+ 0x0+10 +foo = 0x10
+ \[!provide\] +PROVIDE \(foo, bar\)
#...
--
1.9.3