[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Patch] shm cleanups
Andrea Arcangeli <andrea@suse.de> writes:
> Ingo Molnar <mingo@chiara.csoma.elte.hu> writes:
>
> > [Christoph, are you still seeing the same kind of bad swapping behavior
> > with pre1-2.3.26?]
>
> If you still get process killed during heavy swapout (cause OOM of
> an ATOMIC allocation) please try to increase the ATOMIC pool before
> designing a separate pool. We just have a pool for atomic allocation
> it may not be large enough for the increased pressure on the regular pages.
>
> echo 1000 2000 4000 >/proc/sys/vm/freepages
>
> This way you'll basically waste 16mbyte of ram. It's just to check if
> the ATOMIC allocation shortage is the source of the segfault or not.
O.k. with and without these settings 2.3.26-pre2 looks pretty good
about allocating bounce buffers and swapping highmem pages.
To swap shm the first part of the following patch is definitely
needed. The second part makes the machine probably much more useable
if we have problems allocating bounce buffers. Which now hardly ever
happens when stresstesting my 8GB machine.
Linus, could you please apply this?
Christoph
--- 2.3.25/ipc/shm.c Tue Nov 2 12:46:29 1999
+++ make25/ipc/shm.c Thu Nov 4 12:47:14 1999
@@ -788,10 +789,10 @@
unlock_kernel();
return 0;
}
- if (page_count(page_map))
+ if (page_count(page_map) != 1)
goto check_table;
if (!(page_map = prepare_highmem_swapout(page_map)))
- goto check_table;
+ goto failed;
shp->shm_pages[idx] = swp_entry_to_pte(swap_entry);
swap_successes++;
shm_swp++;
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://humbolt.geo.uu.nl/Linux-MM/