title: what does "malloc_trim(0)" really mean?
body: <p>The <a href="http://man7.org/linux/man-pages/man3/malloc_trim.3.html" rel="noreferrer">manual page</a> told me so much and through it I know lots of the background knowledge of memory management of "glibc".</p>
  
  <p>But I still get confused. does "<strong>malloc_trim(0)</strong>"(note zero as the parameter) mean (<em>1.</em>)all the memory in the "heap" section will be returned to OS ? Or (<em>2.</em>)just all "unused" memory of the top most region of the heap will be returned to OS ? </p>
  
  <p>If the answer is (<em>1.</em>), what if the still used memory in the heap? if the heap has used momery at places somewhere, will them be eliminated, or the function wouldn't execute successfully?</p>
  
  <p>While if the answer is (<em>2.</em>), what about those "<strong>holes</strong>" at places rather than top in the heap？　they're unused memory anymore, but the top most region of the heap is still used, will this calling work efficiently?</p>
  
  <p>Thanks.</p>