title: Releasing thread memory
body: <p>When creating a thread, it is allocated its own storage for local variables, etc. When or how is this released back to memory for re-use: when the thread ends?</p>
  
  <p>When a thread tries to allocate a dynamic storage, is it still stored in the thread's local storage or is it stored in a global storage?</p>