The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: Larry McVoy <lm@mcvoy.com>
To: Dan Cross <crossd@gmail.com>
Cc: TUHS main list <tuhs@minnie.tuhs.org>
Subject: Re: [TUHS] If not Linux, then what?
Date: Mon, 26 Aug 2019 19:45:11 -0700	[thread overview]
Message-ID: <20190827024511.GU13570@mcvoy.com> (raw)
In-Reply-To: <CAEoi9W6upO4LdvV0AVLy8f1je6oSZeuz4bbP4yuux-Xe6UUEBA@mail.gmail.com>

On Mon, Aug 26, 2019 at 09:26:27PM -0400, Dan Cross wrote:
> On Mon, Aug 26, 2019, 9:00 PM Arthur Krewat wrote:
> >[snip]
> 
> >
> > As for what mmap() doesn't do right, I started using memory mapped files
> > back in the early 80s on VMS on a VAX-11/780 when I and a colleague were
> > converting a database from TOPS-10 to VMS. Perhaps I am misunderstanding
> > your dislike for mmap() but please, enlighten me. It was my
> > understanding at the time that it was akin to swapping/virtual-memory
> > using an MMU. The difference was that instead of using the main paging
> > area, the kernel would use an actual file.  Why would mmap() be a bad
> > thing, when it's hooked into the kernel, and possibly hardware, at such
> > a low point?
> 
> 
> I don't mean to put words in Larry's mouth, but I think he meant that ZFS
> bypasses the OS page cache, so that file IO and mmap use a different
> buffering scheme that is not mutually consistent. 

Dan is right.  At Sun, when Joe Moran did the 4.x VM system, he put into
place the vision that Bill Joy had.  Which was that the page cache is 
*the* cache.  There is nothing else.  We spent a bunch of time killing
the buffer cache because you couldn't mmap the buffer cache, you could
mmap the page cache.

It's hard to describe how right that was but it was right.  You could
have as many processes as you wanted mmap-ing the same data and there
was a single version of the data.

What ZFS did was manage the data on their own.  So if you mmap-ed a ZFS
file it had to bcopy the data into the page cache and now it is right
back to two copies of the data and you have to manage consistency.

I would have been fine if all page sized blocks were in the page cache
and ZFS managed the less than page sized blocks.  But they punted on
the page cache entirely.

My mind is blown that that was allowed to ship.  The Sun I worked at,
if I had proposed that design, I would have been kicked out of the
kernel group.

  reply	other threads:[~2019-08-27  2:45 UTC|newest]

Thread overview: 96+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-26 23:13 Arthur Krewat
2019-08-26 23:27 ` Warner Losh
2019-08-26 23:37   ` Larry McVoy
2019-08-26 23:56   ` William Pechter
2019-08-27  0:19     ` Arthur Krewat
2019-08-27  0:30       ` Larry McVoy
2019-08-27  0:58         ` Rob Pike
2019-08-27  1:06           ` Clem Cole
2019-08-27  2:53           ` Larry McVoy
2019-08-27  9:47             ` Rob Pike
2019-08-27  7:47           ` arnold
2019-08-27 16:05           ` [TUHS] Running v10 Angelo Papenhoff
2019-08-27 16:27             ` Henry Bent
2019-08-28  4:22               ` Jason Stevens
2019-08-28  7:34                 ` Angelo Papenhoff
2019-08-28 16:46                   ` Henry Bent
2019-08-27  0:59         ` [TUHS] If not Linux, then what? Arthur Krewat
2019-08-27  1:26           ` Dan Cross
2019-08-27  2:45             ` Larry McVoy [this message]
2019-08-27  3:14               ` Arthur Krewat
2019-08-27 14:55                 ` Larry McVoy
2019-08-27 22:30                   ` George Michaelson
2019-08-27 22:40                     ` Larry McVoy
2019-08-27 22:46                       ` George Michaelson
2019-08-27 22:59                         ` [TUHS] [SPAM] " Larry McVoy
2019-08-27 23:10                           ` [TUHS] " Clem Cole
2019-08-28  0:07                             ` George Michaelson
2019-08-28  3:22                           ` [TUHS] [SPAM] " Rob Pike
2019-08-28  3:25                             ` Rob Pike
2019-08-28  4:05                             ` Larry McVoy
2019-08-28 13:52                               ` Clem Cole
2019-08-28 14:31                                 ` [TUHS] " Larry McVoy
2019-08-28 14:57                                   ` Clem Cole
2019-08-28  6:19                         ` Wesley Parish
2019-08-28  6:30                           ` Peter Jeremy
2019-08-28 11:05                             ` Jason Stevens
2019-08-28 11:11                               ` Arrigo Triulzi
2019-08-28 14:04                               ` Clem Cole
2019-08-28 16:34                                 ` Henry Bent
2019-08-28 17:32                                   ` Larry McVoy
2019-08-28 17:51                                     ` Jon Forrest
2019-08-28 18:56                                     ` Clem Cole
2019-08-28 20:23                                       ` Arrigo Triulzi
2019-08-29  3:24                                       ` Lawrence Stewart
2019-08-29 10:55                                         ` Tony Finch
2019-08-28 13:57                             ` Clem Cole
2019-08-28 12:46                           ` Warner Losh
2019-08-27 23:16                       ` Bakul Shah
2019-08-27 23:33                         ` Larry McVoy
2019-08-28  0:21                           ` Bakul Shah
2019-08-28  1:21                             ` Arthur Krewat
2019-08-28  1:46                               ` Larry McVoy
2019-08-27  0:48   ` Clem Cole
2019-08-27  1:25     ` Gregg Levine
2019-08-27  2:16   ` Theodore Y. Ts'o
2019-08-27  2:39     ` Larry McVoy
2019-08-27  5:54       ` Adam Thornton
2019-08-27  6:05         ` Gregg Levine
2019-08-27  1:17 ` Dan Cross
2019-08-28  3:53 ` Charles H. Sauer
2019-08-28  4:30 ` Jason Stevens
2019-08-28  9:36 ` Angus Robinson
2019-08-28  9:50   ` Michael Kjörling
2019-08-28 10:48     ` arnold
2019-08-28 14:10   ` Earl Baugh
2019-08-28 14:55     ` Clem Cole
2019-08-28 14:22   ` Charles H Sauer
2019-08-28 15:00     ` Steve Nickolas
2019-08-28 15:37       ` Richard Salz
2019-08-28 19:54         ` Peter Jeremy
2019-08-28 20:05           ` Christopher Browne
2019-08-28 20:07 ` Christopher Browne
2019-08-28 20:27   ` Adam Thornton
2019-08-28 20:56     ` William Pechter
2019-08-28 22:24       ` Clem cole
2019-08-28 22:27     ` William Pechter
2019-08-28 22:53       ` Arthur Krewat
2019-08-29 18:40       ` Nemo Nusquam
2019-08-29 19:18         ` Steffen Nurpmeso
2019-08-28 22:28     ` Clem cole
2019-08-28 22:48       ` Adam Thornton
2019-08-28 23:01         ` William Pechter
2019-08-28 23:09           ` Adam Thornton
2019-08-29  6:37           ` Wesley Parish
2019-08-28 23:04       ` Gregg Levine
2019-08-29 11:12     ` Tony Finch
2019-08-28 23:19   ` Theodore Y. Ts'o
2019-08-29 13:31     ` A. P. Garcia
2019-08-29 13:55       ` Arthur Krewat
2019-08-29 15:54         ` Thomas Paulsen
2019-08-29 19:19           ` Steffen Nurpmeso
2019-08-31  1:35             ` Dave Horsfall
2019-08-31 15:14               ` Steffen Nurpmeso
2019-08-31 16:58     ` Christopher Browne
2019-08-31 21:20       ` Theodore Y. Ts'o
2019-08-28 21:02 ` Thomas Paulsen

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=20190827024511.GU13570@mcvoy.com \
    --to=lm@mcvoy.com \
    --cc=crossd@gmail.com \
    --cc=tuhs@minnie.tuhs.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;
as well as URLs for NNTP newsgroup(s).