thp: Link THP PDE tests with $(LOAD-THP-ADDRESS-LDFLAGS)
Checks
| Context |
Check |
Description |
| redhat-pt-bot/TryBot-apply_patch |
success
|
Patch applied to master at the time it was sent
|
| redhat-pt-bot/TryBot-32bit |
success
|
Build for i686
|
| linaro-tcwg-bot/tcwg_glibc_build--master-aarch64 |
fail
|
Build failed
|
| linaro-tcwg-bot/tcwg_glibc_build--master-arm |
success
|
Build passed
|
| linaro-tcwg-bot/tcwg_glibc_check--master-arm |
success
|
Test passed
|
Commit Message
LOAD-THP-ADDRESS-LDFLAGS was added to work around:
https://sourceware.org/bugzilla/show_bug.cgi?id=34184
which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
This fixes BZ #34314.
Comments
On 04/07/26 18:41, H.J. Lu wrote:
> LOAD-THP-ADDRESS-LDFLAGS was added to work around:
>
> https://sourceware.org/bugzilla/show_bug.cgi?id=34184
>
> which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
> LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
> by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
> This fixes BZ #34314.
>
>
> From 9eb3c69bac0fdfb4e71b2594d0488774e212c5e3 Mon Sep 17 00:00:00 2001
> From: "H.J. Lu" <hjl.tools@gmail.com>
> Date: Sat, 4 Jul 2026 13:32:10 +0800
> Subject: [PATCH] thp: Link THP PDE tests with $(LOAD-THP-ADDRESS-LDFLAGS)
>
> LOAD-THP-ADDRESS-LDFLAGS was added to work around:
>
> https://sourceware.org/bugzilla/show_bug.cgi?id=34184
>
> which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
> LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
> by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
> This fixes BZ #34314.
>
> Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
LGTM, thanks. For $(build-pie-default)==no tst-thp-1 and tst-thp-1-pde
are essentially the same so maybe only build one in this scenario.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> ---
> sysdeps/unix/sysv/linux/Makefile | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
> index 1efeac5213..0f8fc24b1f 100644
> --- a/sysdeps/unix/sysv/linux/Makefile
> +++ b/sysdeps/unix/sysv/linux/Makefile
> @@ -770,6 +770,9 @@ test-xfail-tst-thp-1-no-s-code-static = yes
> endif
>
> LDFLAGS-tst-thp-1 = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
> +ifneq (yes,$(build-pie-default))
> +LDFLAGS-tst-thp-1 += $(LOAD-THP-ADDRESS-LDFLAGS)
> +endif
> LDFLAGS-tst-thp-1-pde = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS) \
> $(LOAD-THP-ADDRESS-LDFLAGS)
> LDFLAGS-tst-thp-1-static = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
> @@ -778,6 +781,9 @@ LDFLAGS-tst-thp-1-static += $(LOAD-THP-ADDRESS-LDFLAGS)
> endif
> LDFLAGS-tst-thp-1-no-s-code = -Wl,-z,noseparate-code \
> $(THP-PAGE-SIZE-LDFLAGS)
> +ifneq (yes,$(build-pie-default))
> +LDFLAGS-tst-thp-1-no-s-code += $(LOAD-THP-ADDRESS-LDFLAGS)
> +endif
> LDFLAGS-tst-thp-1-no-s-code-pde = -Wl,-z,noseparate-code \
> $(THP-PAGE-SIZE-LDFLAGS) \
> $(LOAD-THP-ADDRESS-LDFLAGS)
> --
> 2.54.0
>
On Wed, Jul 15, 2026 at 7:08 PM Adhemerval Zanella Netto
<adhemerval.zanella@linaro.org> wrote:
>
>
>
> On 04/07/26 18:41, H.J. Lu wrote:
> > LOAD-THP-ADDRESS-LDFLAGS was added to work around:
> >
> > https://sourceware.org/bugzilla/show_bug.cgi?id=34184
> >
> > which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
> > LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
> > by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
> > This fixes BZ #34314.
> >
> >
> > From 9eb3c69bac0fdfb4e71b2594d0488774e212c5e3 Mon Sep 17 00:00:00 2001
> > From: "H.J. Lu" <hjl.tools@gmail.com>
> > Date: Sat, 4 Jul 2026 13:32:10 +0800
> > Subject: [PATCH] thp: Link THP PDE tests with $(LOAD-THP-ADDRESS-LDFLAGS)
> >
> > LOAD-THP-ADDRESS-LDFLAGS was added to work around:
> >
> > https://sourceware.org/bugzilla/show_bug.cgi?id=34184
> >
> > which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
> > LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
> > by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
> > This fixes BZ #34314.
> >
> > Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
>
> LGTM, thanks. For $(build-pie-default)==no tst-thp-1 and tst-thp-1-pde
> are essentially the same so maybe only build one in this scenario.
Pushed. I will see if I can build PIE and PDE explicitly.
> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
>
> > ---
> > sysdeps/unix/sysv/linux/Makefile | 6 ++++++
> > 1 file changed, 6 insertions(+)
> >
> > diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
> > index 1efeac5213..0f8fc24b1f 100644
> > --- a/sysdeps/unix/sysv/linux/Makefile
> > +++ b/sysdeps/unix/sysv/linux/Makefile
> > @@ -770,6 +770,9 @@ test-xfail-tst-thp-1-no-s-code-static = yes
> > endif
> >
> > LDFLAGS-tst-thp-1 = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
> > +ifneq (yes,$(build-pie-default))
> > +LDFLAGS-tst-thp-1 += $(LOAD-THP-ADDRESS-LDFLAGS)
> > +endif
> > LDFLAGS-tst-thp-1-pde = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS) \
> > $(LOAD-THP-ADDRESS-LDFLAGS)
> > LDFLAGS-tst-thp-1-static = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
> > @@ -778,6 +781,9 @@ LDFLAGS-tst-thp-1-static += $(LOAD-THP-ADDRESS-LDFLAGS)
> > endif
> > LDFLAGS-tst-thp-1-no-s-code = -Wl,-z,noseparate-code \
> > $(THP-PAGE-SIZE-LDFLAGS)
> > +ifneq (yes,$(build-pie-default))
> > +LDFLAGS-tst-thp-1-no-s-code += $(LOAD-THP-ADDRESS-LDFLAGS)
> > +endif
> > LDFLAGS-tst-thp-1-no-s-code-pde = -Wl,-z,noseparate-code \
> > $(THP-PAGE-SIZE-LDFLAGS) \
> > $(LOAD-THP-ADDRESS-LDFLAGS)
> > --
> > 2.54.0
> >
>
From 9eb3c69bac0fdfb4e71b2594d0488774e212c5e3 Mon Sep 17 00:00:00 2001
From: "H.J. Lu" <hjl.tools@gmail.com>
Date: Sat, 4 Jul 2026 13:32:10 +0800
Subject: [PATCH] thp: Link THP PDE tests with $(LOAD-THP-ADDRESS-LDFLAGS)
LOAD-THP-ADDRESS-LDFLAGS was added to work around:
https://sourceware.org/bugzilla/show_bug.cgi?id=34184
which is needed for THP PDE tests. Add $(LOAD-THP-ADDRESS-LDFLAGS) to
LDFLAGS-tst-thp-1 and LDFLAGS-tst-thp-1-no-s-code if PIE isn't built
by default so that they are linked with $(LOAD-THP-ADDRESS-LDFLAGS).
This fixes BZ #34314.
Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
---
sysdeps/unix/sysv/linux/Makefile | 6 ++++++
1 file changed, 6 insertions(+)
@@ -770,6 +770,9 @@ test-xfail-tst-thp-1-no-s-code-static = yes
endif
LDFLAGS-tst-thp-1 = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
+ifneq (yes,$(build-pie-default))
+LDFLAGS-tst-thp-1 += $(LOAD-THP-ADDRESS-LDFLAGS)
+endif
LDFLAGS-tst-thp-1-pde = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS) \
$(LOAD-THP-ADDRESS-LDFLAGS)
LDFLAGS-tst-thp-1-static = -Wl,-z,separate-code $(THP-PAGE-SIZE-LDFLAGS)
@@ -778,6 +781,9 @@ LDFLAGS-tst-thp-1-static += $(LOAD-THP-ADDRESS-LDFLAGS)
endif
LDFLAGS-tst-thp-1-no-s-code = -Wl,-z,noseparate-code \
$(THP-PAGE-SIZE-LDFLAGS)
+ifneq (yes,$(build-pie-default))
+LDFLAGS-tst-thp-1-no-s-code += $(LOAD-THP-ADDRESS-LDFLAGS)
+endif
LDFLAGS-tst-thp-1-no-s-code-pde = -Wl,-z,noseparate-code \
$(THP-PAGE-SIZE-LDFLAGS) \
$(LOAD-THP-ADDRESS-LDFLAGS)
--
2.54.0