title: What is the purpose of MAP_ANONYMOUS flag in mmap system call?
body: <p>From the <code>man</code> page,</p>
  
  <pre><code>MAP_ANONYMOUS
                The mapping is not backed by any file; its contents are initialized to zero.  The fd and offset arguments are ignored; however, some implementations  require
                fd  to  be  -1  if  MAP_ANONYMOUS  (or  MAP_ANON)  is  specified, and portable applications should ensure this.  The use of MAP_ANONYMOUS in conjunction with
                MAP_SHARED is only supported on Linux since kernel 2.4.
  </code></pre>
  
  <p>What is the purpose of using <code>MAP_ANONYMOUS</code>? Any example would be good. Also From where the memory will be mapped?</p>
  
  <p>It is written on <code>man</code> page that <code>The use of MAP_ANONYMOUS in conjunction with MAP_SHARED is only supported on Linux since kernel 2.4.</code>
  How can i share the memory mapped with MAP_ANONYMOUS with other process?</p>