<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/src/tree.c, branch cmn/config-get-path</title>
<subtitle>github.com: libgit2/libgit2.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/'/>
<entry>
<title>treebuilder: rename _create() to _new()</title>
<updated>2014-12-27T12:09:11+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-12-27T12:09:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=208a2c8aef59a842d1bec1e6bc83340b1c22c13f'/>
<id>208a2c8aef59a842d1bec1e6bc83340b1c22c13f</id>
<content type='text'>
This function is a constructor, so let's name it like one and leave
_create() for the reference functions, which do create/write the
reference.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This function is a constructor, so let's name it like one and leave
_create() for the reference functions, which do create/write the
reference.
</pre>
</div>
</content>
</entry>
<entry>
<title>treebuilder: take a repository for path validation</title>
<updated>2014-12-17T18:05:27+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2014-12-17T01:24:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=dce7b1a4e75551804a33591744d40d0582c57cfb'/>
<id>dce7b1a4e75551804a33591744d40d0582c57cfb</id>
<content type='text'>
Path validation may be influenced by `core.protectHFS` and
`core.protectNTFS` configuration settings, thus treebuilders
can take a repository to influence their configuration.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Path validation may be influenced by `core.protectHFS` and
`core.protectNTFS` configuration settings, thus treebuilders
can take a repository to influence their configuration.
</pre>
</div>
</content>
</entry>
<entry>
<title>tree: Check for `.git` with case insensitivy</title>
<updated>2014-12-16T16:08:46+00:00</updated>
<author>
<name>Vicent Marti</name>
<email>tanoku@gmail.com</email>
</author>
<published>2014-11-24T23:14:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=62155257d2d30d8f8d7108539df0681dce27ff61'/>
<id>62155257d2d30d8f8d7108539df0681dce27ff61</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>index: fill the tree cache on write-tree</title>
<updated>2014-10-10T17:43:42+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-09-29T07:07:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=7465e873996c4157b8e10e353b803841c548e2dc'/>
<id>7465e873996c4157b8e10e353b803841c548e2dc</id>
<content type='text'>
An obvious place to fill the tree cache is on write-tree, as we're
guaranteed to be able to fill in the whole tree cache.

The way this commit does this is not the most efficient, as we read the
root tree from the odb instead of filling in the cache as we go along,
but it fills the cache such that successive operations (and persisting
the index to disk) will be able to take advantage of the cache, and it
reuses the code we already have for filling the cache.

Filling in the cache as we create the trees would require some
reallocation of the children vector, which is currently not possible
with out pool implementation. A different data structure would likely
allow us to perform this operation at a later date.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
An obvious place to fill the tree cache is on write-tree, as we're
guaranteed to be able to fill in the whole tree cache.

The way this commit does this is not the most efficient, as we read the
root tree from the odb instead of filling in the cache as we go along,
but it fills the cache such that successive operations (and persisting
the index to disk) will be able to take advantage of the cache, and it
reuses the code we already have for filling the cache.

Filling in the cache as we create the trees would require some
reallocation of the children vector, which is currently not possible
with out pool implementation. A different data structure would likely
allow us to perform this operation at a later date.
</pre>
</div>
</content>
</entry>
<entry>
<title>index: write out the tree cache extension</title>
<updated>2014-10-10T17:43:42+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-09-28T05:00:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=c2f8b215937ed6f17dce94a4bde26d5c83b42533'/>
<id>c2f8b215937ed6f17dce94a4bde26d5c83b42533</id>
<content type='text'>
Keeping the cache around after read-tree is only one part of the
optimisation opportunities. In order to share the cache between program
instances, we need to write the TREE extension to the index.

Do so, taking the opportunity to rename 'entries' to 'entry_count' to
match the name given in the format description. The included test is
rather trivial, but works as a sanity check.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Keeping the cache around after read-tree is only one part of the
optimisation opportunities. In order to share the cache between program
instances, we need to write the TREE extension to the index.

Do so, taking the opportunity to rename 'entries' to 'entry_count' to
match the name given in the format description. The included test is
rather trivial, but works as a sanity check.
</pre>
</div>
</content>
</entry>
<entry>
<title>tree: free in error conditions</title>
<updated>2014-06-25T19:25:44+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-06-25T19:25:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=966fb207021830819aad9fce098b4a63838def4d'/>
<id>966fb207021830819aad9fce098b4a63838def4d</id>
<content type='text'>
As reported by coverity, we would leak some memory in error conditions.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As reported by coverity, we would leak some memory in error conditions.
</pre>
</div>
</content>
</entry>
<entry>
<title>treentry: no need for manual size book-keeping</title>
<updated>2014-06-10T13:14:13+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-06-09T20:59:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=fcc60066073b746332eb859c7fccdcece150bfcc'/>
<id>fcc60066073b746332eb859c7fccdcece150bfcc</id>
<content type='text'>
We can simply ask the hasmap.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We can simply ask the hasmap.
</pre>
</div>
</content>
</entry>
<entry>
<title>treebuilder: don't keep removed entries around</title>
<updated>2014-06-10T13:14:13+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-06-09T20:45:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=978fbb4c345e944004e5a2aede17cdd17ab75356'/>
<id>978fbb4c345e944004e5a2aede17cdd17ab75356</id>
<content type='text'>
If the user wants to keep a copy for themselves, they should make a
copy. It adds unnecessary complexity to make sure the returned entries
are valid until the builder is cleared.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the user wants to keep a copy for themselves, they should make a
copy. It adds unnecessary complexity to make sure the returned entries
are valid until the builder is cleared.
</pre>
</div>
</content>
</entry>
<entry>
<title>treebuilder: use a map instead of vector to store the entries</title>
<updated>2014-06-10T13:14:13+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-06-09T02:38:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=4d3f1f97404b01cd00ad5b2f47f64672d787e901'/>
<id>4d3f1f97404b01cd00ad5b2f47f64672d787e901</id>
<content type='text'>
Finding a filename in a vector means we need to resort it every time we
want to read from it, which includes every time we want to write to it
as well, as we want to find duplicate keys.

A hash-map fits what we want to do much more accurately, as we do not
care about sorting, but just the particular filename.

We still keep removed entries around, as the interface let you assume
they were going to be around until the treebuilder is cleared or freed,
but in this case that involves an append to a vector in the filter case,
which can now fail.

The only time we care about sorting is when we write out the tree, so
let's make that the only time we do any sorting.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Finding a filename in a vector means we need to resort it every time we
want to read from it, which includes every time we want to write to it
as well, as we want to find duplicate keys.

A hash-map fits what we want to do much more accurately, as we do not
care about sorting, but just the particular filename.

We still keep removed entries around, as the interface let you assume
they were going to be around until the treebuilder is cleared or freed,
but in this case that involves an append to a vector in the filter case,
which can now fail.

The only time we care about sorting is when we write out the tree, so
let's make that the only time we do any sorting.
</pre>
</div>
</content>
</entry>
<entry>
<title>treebuilder: insert sorted</title>
<updated>2014-06-09T22:06:21+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2014-06-09T21:23:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=2c11d2eeb550ed2f795c714829b3fd3788b2ab68'/>
<id>2c11d2eeb550ed2f795c714829b3fd3788b2ab68</id>
<content type='text'>
By inserting in the right position, we can keep the vector sorted,
making entry insertion almost twice as fast.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
By inserting in the right position, we can keep the vector sorted,
making entry insertion almost twice as fast.
</pre>
</div>
</content>
</entry>
</feed>
