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

Re: [PATCH 3/9] submodule.c: sort changed_submodule_names before searching it

From
JTJonathan Tan <jonathantanmy@google.com>
Date
Dec 5, 2018, 00:12 UTC
Message-ID
<20181205001246.71899-1-jonathantanmy@google.com>
In-Reply-To
<20181129002756.167615-4-sbeller@google.com>
Show 7 quoted lines
> We can string_list_insert() to maintain sorted-ness of the
> list as we find new items, or we can string_list_append() to
> build an unsorted list and sort it at the end just once.
> 
> As we do not rely on the sortedness while building the
> list, we pick the "append and sort at the end" as it
> has better worst case execution times.
I would write this entire commit message as:
  Instead of using unsorted_string_list_lookup(), sort
  changed_submodule_names before performing any lookups so that we can
  use the faster string_list_lookup() instead.
The code in this patch is fine, and patches 1-2 are fine too.
Previous: Stefan BellerNext: Stefan Beller
Message 5 of 21 in “[PATCHv2 0/9] Resending sb/submodule-recursive-fetch-gets-the-tip”
  1. Stefan BellerNov 29, 2018
  2. 1/9 sha1-array: provide oid_array_filterStefan Beller, Nov 29, 2018
  3. 2/9 submodule.c: fix indentationStefan Beller, Nov 29, 2018
  4. 3/9 submodule.c: sort changed_submodule_names before searching itStefan Beller, Nov 29, 2018
  5. Jonathan TanDec 5, 2018
  6. 4/9 submodule.c: tighten scope of changed_submodule_names structStefan Beller, Nov 29, 2018
  7. 5/9 submodule: store OIDs in changed_submodule_namesStefan Beller, Nov 29, 2018
  8. 6/9 repository: repo_submodule_init to take a submodule structStefan Beller, Nov 29, 2018
  9. 7/9 submodule: migrate get_next_submodule to use repository structsStefan Beller, Nov 29, 2018
  10. Jonathan TanDec 5, 2018
  11. Jonathan NiederFeb 2, 2019
  12. 8/9 submodule.c: fetch in submodules git directory instead of in worktreeStefan Beller, Nov 29, 2018
  13. Jonathan TanDec 5, 2018
  14. 9/9 fetch: try fetching submodules if needed objects were not fetchedStefan Beller, Nov 29, 2018
  15. Jonathan TanDec 5, 2018
  16. fetch: ensure submodule objects fetchedStefan Beller, Dec 6, 2018
  17. Junio C HamanoDec 9, 2018
  18. Junio C HamanoDec 5, 2018
  19. Stefan BellerDec 6, 2018
  20. Josh SteadmonDec 7, 2018
  21. Jonathan NiederJan 15, 2019

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.