Message ID | cf5e65ba1eb9652008a9ca21a5502bf7907af6c3.1727624528.git.fweimer@redhat.com |
---|---|
State | New |
Headers | show |
Series | Teach glibc about possible page sizes and handle gaps in ld.so | expand |
On 9/29/24 08:59, Florian Weimer wrote: > According to arch/arc/Kconfig in the Linux kernel sources, arc > supports pagge sizes 4 KiB, 8 KiB, 16 KiB. However, > the toolchain defaults are not compatible with 16 KiB pages, so > xfail the future elf/tst-load-alignment test. > > (Note: Alternatively, we could fix the maximum page size at 8 KiB, > if that's closer to reality.) Indeed 16K size was more esoteric and dates back to older ARC700 cpus (not supported in glibc anyways) And 8K is indeed the default for ARCompact and ARCv2 ISA cores. -Vineet > --- > sysdeps/arc/bits/pagesize.h | 2 ++ > sysdeps/unix/sysv/linux/arc/Makefile | 5 +++++ > 2 files changed, 7 insertions(+) > create mode 100644 sysdeps/arc/bits/pagesize.h > > diff --git a/sysdeps/arc/bits/pagesize.h b/sysdeps/arc/bits/pagesize.h > new file mode 100644 > index 0000000000..16a4d49136 > --- /dev/null > +++ b/sysdeps/arc/bits/pagesize.h > @@ -0,0 +1,2 @@ > +#define __GLIBC_PAGE_SHIFT_MIN 12 > +#define __GLIBC_PAGE_SHIFT_MAX 14 > diff --git a/sysdeps/unix/sysv/linux/arc/Makefile b/sysdeps/unix/sysv/linux/arc/Makefile > index dd3da52c39..cfade7a347 100644 > --- a/sysdeps/unix/sysv/linux/arc/Makefile > +++ b/sysdeps/unix/sysv/linux/arc/Makefile > @@ -1,3 +1,8 @@ > +ifeq ($(subdir),elf) > +# The toolchain defaults to 8K pages even though Linux supports 16K pages. > +test-xfail-tst-load-alignment = yes > +endif > + > ifeq ($(subdir),stdlib) > gen-as-const-headers += ucontext_i.sym > endif
* Vineet Gupta: > On 9/29/24 08:59, Florian Weimer wrote: >> According to arch/arc/Kconfig in the Linux kernel sources, arc >> supports pagge sizes 4 KiB, 8 KiB, 16 KiB. However, >> the toolchain defaults are not compatible with 16 KiB pages, so >> xfail the future elf/tst-load-alignment test. >> >> (Note: Alternatively, we could fix the maximum page size at 8 KiB, >> if that's closer to reality.) > > Indeed 16K size was more esoteric and dates back to older ARC700 cpus > (not supported in glibc anyways) And 8K is indeed the default for > ARCompact and ARCv2 ISA cores. >> +#define __GLIBC_PAGE_SHIFT_MIN 12 >> +#define __GLIBC_PAGE_SHIFT_MAX 14 Do you suggest to change the maximum shift to 13? Sorry, it's not clear based on your comment. Thanks, Florian
diff --git a/sysdeps/arc/bits/pagesize.h b/sysdeps/arc/bits/pagesize.h new file mode 100644 index 0000000000..16a4d49136 --- /dev/null +++ b/sysdeps/arc/bits/pagesize.h @@ -0,0 +1,2 @@ +#define __GLIBC_PAGE_SHIFT_MIN 12 +#define __GLIBC_PAGE_SHIFT_MAX 14 diff --git a/sysdeps/unix/sysv/linux/arc/Makefile b/sysdeps/unix/sysv/linux/arc/Makefile index dd3da52c39..cfade7a347 100644 --- a/sysdeps/unix/sysv/linux/arc/Makefile +++ b/sysdeps/unix/sysv/linux/arc/Makefile @@ -1,3 +1,8 @@ +ifeq ($(subdir),elf) +# The toolchain defaults to 8K pages even though Linux supports 16K pages. +test-xfail-tst-load-alignment = yes +endif + ifeq ($(subdir),stdlib) gen-as-const-headers += ucontext_i.sym endif