From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [Question] New mmap64 syscall?
Date: Wed, 07 Dec 2016 22:30:24 +0100 [thread overview]
Message-ID: <12011325.PfzMMUCfyS@wuerfel> (raw)
In-Reply-To: <DF57E4A6-85C9-44EF-AD03-19EA688D19DB@theobroma-systems.com>
On Wednesday, December 7, 2016 5:43:27 PM CET Dr. Philipp Tomsich wrote:
> Catalin,
>
> > On 07 Dec 2016, at 17:32, Catalin Marinas <catalin.marinas@arm.com> wrote:
> >
> >>> In other words: Why not keep ILP32 simple an ask users that need a 16TB+ offset
> >>> to use LP64? It seems much more consistent with the other choices takes so far.
> >>
> >> If user can switch to lp64, he doesn't need ilp32 at all, right?
> >> Also, I don't understand how true 64-bit offset in mmap64() would
> >> complicate this port.
> >
> > It's more like the user wanting a quick transition from code that was
> > only ever compiled for AArch32 (or other 32-bit architecture) with a
> > goal of full LP64 transition on the long run. I have yet to see
> > convincing benchmarks showing ILP32 as an advantage over LP64 (of
> > course, I hear the argument of reading a pointer a loop is twice as fast
> > with a half-size pointer but I don't consider such benchmarks relevant).
>
> Most of the performance advantage in benchmarks comes from a reduction
> in the size of data-structures and/or tighter packing of arrays. In other words,
> we can make slightly better use of the caches and push the memory subsystem
> a little further when running multiple instances of benchmarks.
>
> Most of these advantages should eventually go away, when struct-reorg makes
> it way into the compiler. That said, it?s a marginal (but real) improvement for a
> subset of SPEC.
>
> In the real world, the importance of ILP32 as an aid to transition legacy code
> that is not 64bit clean? and this should drive the ILP32 discussion. That we
> get a boost in our SPEC scores is just a nice extra that we get from it
To bring this back from the philosophical questions of ABI design
to the specific point of what file offset width you want for mmap()
on 32-bit architectures.
For all I can tell, using mmap() to access a file that is many thousand
times larger than your virtual address space is completely crazy.
Adding a new mmap64() syscall on all 32-bit architectures would be
trivial if there was a use case for it, without one we but without at
least one specific application asking for it (with good reasons), we
shouldn't even be talking about that.
Note that until commit f8b7256096a2 ("Unify sys_mmap"), we actually
had a sys_mmap64 implementation on a couple of architectures, but
removed it.
Arnd
next prev parent reply other threads:[~2016-12-07 21:30 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-06 18:54 [Question] New mmap64 syscall? Yury Norov
2016-12-06 21:20 ` Arnd Bergmann
2016-12-07 10:34 ` Yury Norov
2016-12-07 11:07 ` Dr. Philipp Tomsich
2016-12-07 12:39 ` Yury Norov
2016-12-07 16:32 ` Catalin Marinas
2016-12-07 16:43 ` Dr. Philipp Tomsich
2016-12-07 21:30 ` Arnd Bergmann [this message]
2016-12-10 9:10 ` Pavel Machek
2016-12-10 9:21 ` Pavel Machek
2016-12-11 12:56 ` Yury Norov
2016-12-11 12:56 ` [PATCH 1/3] mm: move argument checkers of mmap_pgoff() to separated routine Yury Norov
2016-12-11 12:56 ` [PATCH 2/3] sys_mmap64() Yury Norov
2016-12-11 14:48 ` kbuild test robot
2016-12-11 14:56 ` kbuild test robot
2016-12-11 12:56 ` [PATCH 3/3] mm: make pagoff_t type 64-bit Yury Norov
2016-12-11 13:31 ` kbuild test robot
2016-12-11 13:41 ` kbuild test robot
2016-12-11 14:59 ` Arnd Bergmann
2016-12-16 10:55 ` Yury Norov
2016-12-16 11:02 ` Arnd Bergmann
2016-12-18 9:23 ` Christoph Hellwig
2016-12-07 13:23 ` [Question] New mmap64 syscall? Florian Weimer
2016-12-07 15:48 ` Yury Norov
2016-12-08 15:47 ` Florian Weimer
2017-01-03 20:54 ` Pavel Machek
2017-01-12 16:13 ` Florian Weimer
2017-01-12 21:51 ` Pavel Machek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=12011325.PfzMMUCfyS@wuerfel \
--to=arnd@arndb.de \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox