[HACKERS] Async IO description

From: Zeugswetter Andreas SARZ <Andreas(dot)Zeugswetter(at)telecom(dot)at>
To: "'hackers(at)postgreSQL(dot)org'" <hackers(at)postgreSQL(dot)org>
Subject: [HACKERS] Async IO description
Date: 1998-04-22 16:10:14
Message-ID: 219F68D65015D011A8E000006F8590C6010A5256@sdexcsrv1.sd.spardat.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


> When using aio for file or raw device access the following functions
> have to be used (from sys/aio.h):
>
int aio_read(int, struct aiocb *);
int aio_write(int, struct aiocb *);
int aio_cancel(int, struct aiocb *);
int aio_suspend(int, struct aiocb *[]);

The main advantage is not read ahead or the like (read ahead can be
accomplished with other means, e.g. separate reader and writer
processes).
The main advantage is, that a process that calls these for IO will
not
be suspended by the OPsys, and can therefore do other work
until the data is available. On fast disks the data will be
available
before the process time slice (20 - 50 ms) is over !
A process using normal read or write will have to wait until
all other processes have consumed their time slice.

I think the first step should be separate global IO processes,
these could then in a second step use aio.

Andreas

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Zeugswetter Andreas SARZ 1998-04-22 16:41:35 patch for explain.c that shows index (il secondo)
Previous Message Kent S. Gordon 1998-04-22 16:00:19 Re: [HACKERS] Re: [QUESTIONS] How to use memory instead of hd?