diff options
| author | Andi Kleen <ak@muc.de> | 2002-06-17 20:27:43 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-06-17 20:27:43 -0700 |
| commit | 30724dcd73d7d0baf54250e5e80c97b8f49e210e (patch) | |
| tree | 3d6e50a640c47a38a3f091e6453ef7d4b7677f17 /kernel/context.c | |
| parent | 86403107ccc75a0562ecdf21b3adc07285b83daa (diff) | |
[PATCH] poll/select fast path
This patch streamlines poll and select by adding fast paths for a
small number of descriptors passed. The majority of polls/selects
seem to be of this nature. The main saving comes from not allocating
two pages for wait queue and table, but from using stack allocation
(upto 256bytes) when only a few descriptors are needed. This makes
it as fast again as 2.0 and even a bit faster because the wait queue
page allocation is avoided too (except when the drivers overflow it)
select also skips a lot faster over big holes and avoids the separate
pass of determining the max. number of descriptors in the bitmap.
A typical linux system saves a considerable amount of unswappable memory
with this patch, because it usually has 10+ daemons hanging around in poll or
select with each two pages allocated for data and wait queue.
Some other cleanups.
Diffstat (limited to 'kernel/context.c')
0 files changed, 0 insertions, 0 deletions
