* [PATCH] Fix sim/testsuite/bpf due to linker warnings
@ 2023-01-04 4:12 Guillermo E. Martinez
2023-01-04 7:02 ` Mike Frysinger
2023-01-04 21:41 ` [PATCHv2] " Guillermo E. Martinez
0 siblings, 2 replies; 5+ messages in thread
From: Guillermo E. Martinez @ 2023-01-04 4:12 UTC (permalink / raw)
To: binutils; +Cc: jose.marchesi, Guillermo E. Martinez
Hello,
This patch is meant to fix bug:
https://sourceware.org/bugzilla/show_bug.cgi?id=29954
Please let know your thoughts. I'll really appreciate them!,
guillermo
--
On a bpf-*-* testsuite fails:
./ld/ld-new: warning: test has a LOAD segment with RWX permissions
Adding `--no-warn-rwx-segments' option to linker and set `--memory-size=10Mb'
to the simulator bpf testsuite passes.
Tested on bpf-*-*:
Bug 29954: https://sourceware.org/bugzilla/show_bug.cgi?id=29954
sim/testsuite:
* bpf/allinsn.exp (SIMFLAGS_FOR_TARGET): Adjust sim flags.
(LDFLAGS_FOR_TARGET): Adjust ld flags.
---
sim/testsuite/bpf/allinsn.exp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sim/testsuite/bpf/allinsn.exp b/sim/testsuite/bpf/allinsn.exp
index 98f0346776a..758ecc1b414 100644
--- a/sim/testsuite/bpf/allinsn.exp
+++ b/sim/testsuite/bpf/allinsn.exp
@@ -6,10 +6,10 @@ sim_init
set all_machs "bpf"
global SIMFLAGS_FOR_TARGET
-set SIMFLAGS_FOR_TARGET "--memory-size=4Mb"
+set SIMFLAGS_FOR_TARGET "--memory-size=10Mb"
global LDFLAGS_FOR_TARGET
-set LDFLAGS_FOR_TARGET "-Ttext=0x0"
+set LDFLAGS_FOR_TARGET "--no-warn-rwx-segments"
foreach src [lsort [glob -nocomplain $srcdir/$subdir/*.s]] {
# If we're only testing specific files and this isn't one of them, skip it.
--
2.39.0
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Fix sim/testsuite/bpf due to linker warnings
2023-01-04 4:12 [PATCH] Fix sim/testsuite/bpf due to linker warnings Guillermo E. Martinez
@ 2023-01-04 7:02 ` Mike Frysinger
2023-01-04 17:24 ` Guillermo E. Martinez
2023-01-04 21:41 ` [PATCHv2] " Guillermo E. Martinez
1 sibling, 1 reply; 5+ messages in thread
From: Mike Frysinger @ 2023-01-04 7:02 UTC (permalink / raw)
To: Guillermo E. Martinez; +Cc: binutils, jose.marchesi
[-- Attachment #1: Type: text/plain, Size: 803 bytes --]
On 03 Jan 2023 22:12, Guillermo E. Martinez via Binutils wrote:
> Hello,
>
> This patch is meant to fix bug:
> https://sourceware.org/bugzilla/show_bug.cgi?id=29954
>
> Please let know your thoughts. I'll really appreciate them!,
> guillermo
>
> --
>
> On a bpf-*-* testsuite fails:
> ./ld/ld-new: warning: test has a LOAD segment with RWX permissions
>
> Adding `--no-warn-rwx-segments' option to linker and set `--memory-size=10Mb'
> to the simulator bpf testsuite passes.
>
> Tested on bpf-*-*:
>
> Bug 29954: https://sourceware.org/bugzilla/show_bug.cgi?id=29954
i thought increasing the memory was sufficient to not need the -Ttext=0x0,
and the -Ttext=0x0 was the only reason we were triggering RWX warnings. so
do we still need --no-warn-rwx-segments ?
-mike
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Fix sim/testsuite/bpf due to linker warnings
2023-01-04 7:02 ` Mike Frysinger
@ 2023-01-04 17:24 ` Guillermo E. Martinez
0 siblings, 0 replies; 5+ messages in thread
From: Guillermo E. Martinez @ 2023-01-04 17:24 UTC (permalink / raw)
To: Mike Frysinger; +Cc: binutils, jose.marchesi
Hello Mike,
On Wed, Jan 04, 2023 at 02:02:26AM -0500, Mike Frysinger wrote:
> On 03 Jan 2023 22:12, Guillermo E. Martinez via Binutils wrote:
> > Hello,
> >
> > This patch is meant to fix bug:
> > https://sourceware.org/bugzilla/show_bug.cgi?id=29954
> >
> > Please let know your thoughts. I'll really appreciate them!,
> > guillermo
> >
> > --
> >
> > On a bpf-*-* testsuite fails:
> > ./ld/ld-new: warning: test has a LOAD segment with RWX permissions
> >
> > Adding `--no-warn-rwx-segments' option to linker and set `--memory-size=10Mb'
> > to the simulator bpf testsuite passes.
> >
> > Tested on bpf-*-*:
> >
> > Bug 29954: https://sourceware.org/bugzilla/show_bug.cgi?id=29954
>
> i thought increasing the memory was sufficient to not need the -Ttext=0x0,
> and the -Ttext=0x0 was the only reason we were triggering RWX warnings. so
> do we still need --no-warn-rwx-segments ?
> -mike
Oh, that's right thanks for pointing out it, I'll send patch-v2.
thanks,
guillermo
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCHv2] Fix sim/testsuite/bpf due to linker warnings
2023-01-04 4:12 [PATCH] Fix sim/testsuite/bpf due to linker warnings Guillermo E. Martinez
2023-01-04 7:02 ` Mike Frysinger
@ 2023-01-04 21:41 ` Guillermo E. Martinez
2023-01-05 1:54 ` Mike Frysinger
1 sibling, 1 reply; 5+ messages in thread
From: Guillermo E. Martinez @ 2023-01-04 21:41 UTC (permalink / raw)
To: binutils; +Cc: Guillermo E. Martinez
Hello,
This is the patch-v2 to fix the bug:
https://sourceware.org/bugzilla/show_bug.cgi?id=29954
Changes from v1:
+ Remove LDFLAGS_FOR_TARGET and its assignment.
Please let know your thoughts. I'll really appreciate them!,
guillermo
--
On a bpf-*-* testsuite fails:
./ld/ld-new: warning: test has a LOAD segment with RWX permissions
Adjusting `--memory-size=10Mb' to the simulator bpf testsuite passes.
Tested on bpf-*-*:
Bug 29954: https://sourceware.org/bugzilla/show_bug.cgi?id=29954
sim/testsuite:
* bpf/allinsn.exp (SIMFLAGS_FOR_TARGET): Adjust sim flags.
---
sim/testsuite/bpf/allinsn.exp | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/sim/testsuite/bpf/allinsn.exp b/sim/testsuite/bpf/allinsn.exp
index 98f0346776a..1da0b9756c7 100644
--- a/sim/testsuite/bpf/allinsn.exp
+++ b/sim/testsuite/bpf/allinsn.exp
@@ -6,10 +6,7 @@ sim_init
set all_machs "bpf"
global SIMFLAGS_FOR_TARGET
-set SIMFLAGS_FOR_TARGET "--memory-size=4Mb"
-
-global LDFLAGS_FOR_TARGET
-set LDFLAGS_FOR_TARGET "-Ttext=0x0"
+set SIMFLAGS_FOR_TARGET "--memory-size=10Mb"
foreach src [lsort [glob -nocomplain $srcdir/$subdir/*.s]] {
# If we're only testing specific files and this isn't one of them, skip it.
--
2.39.0
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCHv2] Fix sim/testsuite/bpf due to linker warnings
2023-01-04 21:41 ` [PATCHv2] " Guillermo E. Martinez
@ 2023-01-05 1:54 ` Mike Frysinger
0 siblings, 0 replies; 5+ messages in thread
From: Mike Frysinger @ 2023-01-05 1:54 UTC (permalink / raw)
To: Guillermo E. Martinez; +Cc: binutils
[-- Attachment #1: Type: text/plain, Size: 80 bytes --]
thanks, verified it worked for me, tweaked the commit message, and pushed
-mike
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-01-05 1:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-04 4:12 [PATCH] Fix sim/testsuite/bpf due to linker warnings Guillermo E. Martinez
2023-01-04 7:02 ` Mike Frysinger
2023-01-04 17:24 ` Guillermo E. Martinez
2023-01-04 21:41 ` [PATCHv2] " Guillermo E. Martinez
2023-01-05 1:54 ` Mike Frysinger
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).