Skip site navigation (1) Skip section navigation (2)

Re: adding support for posix_fadvise()

From: Neil Conway <neilc(at)samurai(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Hannu Krosing <hannu(at)tm(dot)ee>,PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: adding support for posix_fadvise()
Date: 2003-11-03 16:59:24
Message-ID: 1067878764.3089.369.camel@tokyo (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
On Mon, 2003-11-03 at 11:11, Tom Lane wrote:
> Why not?  The advice says that you're going to access the data
> sequentially in the forward direction.  If you're not going to back up,
> there is no point in keeping pages in cache after they've been read.

The advice says: "I'm going to read this data sequentially, going
forward." It doesn't say: "I'm only going to read the data once, and
then not access it again" (ISTM that's what FADV_NOREUSE is for). For
example, the following is a perfectly reasonable sequential access


(i.e. repeatedly scanning through a large file, say for a data-analysis
app that does multiple passes over the input data). It might not be a
particularly common database reference pattern, but just because an app
is doing a sequential read says little about the temporal locality of
references to the pages in question.


In response to


pgsql-hackers by date

Next:From: Hannu KrosingDate: 2003-11-03 17:17:40
Subject: Re: adding support for posix_fadvise()
Previous:From: Neil ConwayDate: 2003-11-03 16:47:55
Subject: Re: equal() perf tweak

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group