lkml.org 
[lkml]   [2005]   [May]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: How to use memory over 4GB
At 17.10 16/05/2005, William Lee Irwin III wrote:

>On Mon, May 16, 2005 at 03:16:28PM +0200, Roberto Fichera wrote:
> > I was thinking to create as many object I need by the usual shm_open(),
> > than mmap() it on a process until I get ENOMEM. So, when I get a
> > ENOMEM I start to munmap() objects in order to free some user space
> > memory and create the needed space to complete mmap() for the
> > requested object.
>
>This approach has already been used in production by various major
>applications and is even obsolete, now replaced by remap_file_pages()
>(in Linux), where it and its counterparts in other operating systems
>have been in use in production by various major applications for some time.
>
>remap_file_pages() allows virtual pages in an mmap() area to correspond
>in an unrestricted fashion to the pages of the underlying file, and to
>alter this correspondence at will.
>
>In particular, Oracle's "vlm" option does this.

So, you are suggesting to create one big tmpfs area, 6GB for example, than
mmap() it
to the user process and use the remap_file_pages() for all the objects I
want make
"addressable" on the user process taking care the return value of -1 which
implies
to munmap() something to free vm space?



>-- wli

Roberto Fichera.

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

\
 
 \ /
  Last update: 2005-05-16 17:54    [W:0.095 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site