AIX disclaim() or Tru64 madvise (MADV_DONTNEED) needed

Christoph Rohland (hans-christoph.rohland@sap-ag.de)
20 Aug 1999 14:36:05 +0200


Hi all,

For really good operation of SAP R/3 we would need a call like AIX's
disclaim or Tru64's madvise(MADV_DONTNEED): From 'man madvise' of
Tru64:

'MADV_DONTNEED
Do not need these pages

The system will free any whole pages in the specified
region. All modifications will be lost and any swapped
out pages will be discarded. Subsequent access to the
region will result in a zero-fill-on-demand fault as
though it is being accessed for the first time...'

We need this to free up memory used in a transaction but no longer
needed. In the special case of R/3 this memory resides only in SYSV
shm.

I looked into the shm code and to implement this special case would be
very easy, but I believe it should probably be implemented for all
anonymous or shared pages.

Also I am not sure which API should be used:
(1) madvise is known on many systems, but they do not agree about the
meaning of MADV_DONTNEED. Most of them only use it as hint to page
this area out. Perhaps a flag MADV_FREE or MADV_DISCLAIM would be
better.
(2) disclaim is AIX specific and not known to other systems.

Any comments?
Christoph

-- 
______________________________________________
 Christoph Rohland, LinuxLab, SAP-AG, Germany

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/