git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2] read-cache: free threaded memory pool

From
Patrick Steinhardt <ps@pks.im>
Date
Oct 2, 2024, 10:49 UTC
Message-ID
<Zv0lISjo-5bHzEzW@pks.im>
In-Reply-To
<pull.1801.v2.git.1727804265033.gitgitgadget@gmail.com>
On Tue, Oct 01, 2024 at 05:37:44PM +0000, Derrick Stolee via GitGitGadget wrote:
Show 10 quoted lines
> From: Derrick Stolee <stolee@gmail.com>
> 
> In load_cache_entries_threaded(), each thread allocates its own memory
> pool. This pool needs to be cleaned up while closing the threads down,
> or it will be leaked.
> 
> This ce_mem_pool pointer could theoretically be converted to an inline
> copy of the struct, but the use of a pointer helps with existing lazy-
> initialization logic. Adjusting that behavior only to avoid this pointer
> would be a much bigger change.
Thanks, this looks good to me.
Patrick
Previous: Derrick Stolee via GitGitGadget
Message 11 of 11 in “read-cache: two small leak fixes”
  1. 0/2 read-cache: two small leak fixesDerrick Stolee via GitGitGadget, Sep 30, 2024
  2. 1/2 read-cache: free threaded memory poolDerrick Stolee via GitGitGadget, Sep 30, 2024
  3. Patrick SteinhardtSep 30, 2024
  4. Derrick StoleeOct 1, 2024
  5. Patrick SteinhardtOct 1, 2024
  6. 2/2 read-cache: free hash context in do_write_index()Derrick Stolee via GitGitGadget, Sep 30, 2024
  7. Patrick SteinhardtSep 30, 2024
  8. Derrick StoleeOct 1, 2024
  9. Patrick SteinhardtOct 1, 2024
  10. read-cache: free threaded memory poolDerrick Stolee via GitGitGadget, Oct 1, 2024
  11. Patrick SteinhardtOct 2, 2024

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.