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 pattern: a,b,c,a,b,c,a,b,c,a,b,c (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. -Neil ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]