<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/fetch.c, branch v0.99.8e</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://www.git.shady.money/git/atom?h=v0.99.8e</id>
<link rel='self' href='https://www.git.shady.money/git/atom?h=v0.99.8e'/>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/'/>
<updated>2005-09-27T07:16:40Z</updated>
<entry>
<title>[PATCH] Implement --recover for git-*-fetch</title>
<updated>2005-09-27T07:16:40Z</updated>
<author>
<name>Daniel Barkalow</name>
<email>barkalow@iabervon.org</email>
</author>
<published>2005-09-27T01:38:08Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=820eca68c2577d7499d203d7f4f7ae479b577683'/>
<id>urn:sha1:820eca68c2577d7499d203d7f4f7ae479b577683</id>
<content type='text'>
With the --recover option, we verify that we have absolutely
everything reachable from the target, not assuming that things
reachable from refs will be complete.

Signed-off-by: Daniel Barkalow &lt;barkalow@iabervon.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Plug memory leak in process_tree()</title>
<updated>2005-09-23T21:30:45Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-23T12:28:18Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=d35bbe0b2e3765639c23978783a5319dfad33992'/>
<id>urn:sha1:d35bbe0b2e3765639c23978783a5319dfad33992</id>
<content type='text'>
When freeing a tree entry, must free its name too.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Do not build object ref lists</title>
<updated>2005-09-23T21:30:42Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-23T12:28:13Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=a95cb6fb6b247cf90bd0b1a8bf989a0b42ada775'/>
<id>urn:sha1:a95cb6fb6b247cf90bd0b1a8bf989a0b42ada775</id>
<content type='text'>
The fetch code does not need object ref lists; by disabling them we
can save some time and memory.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Remove call to parse_object() from process()</title>
<updated>2005-09-23T04:52:12Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:29Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=2c08b3638339f9b73128c41a4882e115222608a3'/>
<id>urn:sha1:2c08b3638339f9b73128c41a4882e115222608a3</id>
<content type='text'>
The call to parse_object() in process() is not actually needed - if
the object type is unknown, parse_object() will be called by loop();
if the type is known, the object will be parsed by the appropriate
process_*() function.

After this change blobs which exist locally are no longer parsed,
which gives about 2x CPU usage improvement; the downside is that there
will be no warnings for existing corrupted blobs, but detecting such
corruption is the job of git-fsck-objects, not the fetch programs.
Newly fetched objects are still checked for corruption in http-fetch.c
and ssh-fetch.c (local-fetch.c does not seem to do it, but the removed
parse_object() call would not be reached for new objects anyway).

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Clean up object flag definitions</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:24Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=24451c31032d4ea3e7750b5f9c61e9c9f1657449'/>
<id>urn:sha1:24451c31032d4ea3e7750b5f9c61e9c9f1657449</id>
<content type='text'>
Remove holes left after deleting flags, and use shifts to emphasize
that flags are single bits.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Remove redundant test of TO_SCAN in process()</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:19Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=2449696bcd8b458ae604c35898ecab7271b97b40'/>
<id>urn:sha1:2449696bcd8b458ae604c35898ecab7271b97b40</id>
<content type='text'>
If the SEEN flag was not set, the TO_SCAN flag cannot be set,
therefore testing it is pointless.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Remove some duplicated code in process()</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:14Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=7b64d06b2e74612a0970c8563845cb9ee34724af'/>
<id>urn:sha1:7b64d06b2e74612a0970c8563845cb9ee34724af</id>
<content type='text'>
It does not matter if we call prefetch() or set the TO_SCAN flag before
or after adding the object to process_queue.  However, doing it before
object_list_insert() allows us to kill 3 lines of duplicated code.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Remove redundant TO_FETCH flag</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:09Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=51d8faf8608aa8d2f6a8c4b3c1b712adb0d39325'/>
<id>urn:sha1:51d8faf8608aa8d2f6a8c4b3c1b712adb0d39325</id>
<content type='text'>
The TO_FETCH flag also became redundant after adding the SEEN flag -
it was set and checked in process() to prevent adding the same object
to process_queue multiple times, but now SEEN guards against this.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Remove redundant SCANNED flag</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:34:04Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=754ac00e710386ab575843225768d4885c11c8c4'/>
<id>urn:sha1:754ac00e710386ab575843225768d4885c11c8c4</id>
<content type='text'>
After adding the SEEN flag, the SCANNED flag became obviously
redundant - each object can get into process_queue through process()
only once, and therefore multiple calls to process_object() for the
same object are not possible.

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>[PATCH] fetch.c: Make process() look at each object only once</title>
<updated>2005-09-23T04:52:11Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2005-09-21T16:33:59Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=a82d07e5e61a9aef38d70277a5b27588a939c5ce'/>
<id>urn:sha1:a82d07e5e61a9aef38d70277a5b27588a939c5ce</id>
<content type='text'>
The process() function is very often called multiple times for the
same object (because lots of trees refer to the same blobs), but did
not have a fast check for this, therefore a lot of useless calls to
has_sha1_file() and parse_object() were made before discovering that
nothing needs to be done.

This patch adds the SEEN flag which is used in process() to make it
look at each object only once.  When testing git-local-fetch on the
repository of GIT, this gives a 14x improvement in CPU usage (mainly
because the redundant calls to parse_object() are now avoided -
parse_object() always unpacks and parses the object data, even if it
was already parsed before).

Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
</feed>
