<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/diff.c, branch v1.5.0-rc3</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v1.5.0-rc3</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v1.5.0-rc3'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2007-01-08T23:44:47Z</updated>
<entry>
<title>short i/o: fix calls to write to use xwrite or write_in_full</title>
<updated>2007-01-08T23:44:47Z</updated>
<author>
<name>Andy Whitcroft</name>
<email>apw@shadowen.org</email>
</author>
<published>2007-01-08T15:58:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=93822c2239a336e5cb583549071c59202ef6c5b2'/>
<id>urn:sha1:93822c2239a336e5cb583549071c59202ef6c5b2</id>
<content type='text'>
We have a number of badly checked write() calls.  Often we are
expecting write() to write exactly the size we requested or fail,
this fails to handle interrupts or short writes.  Switch to using
the new write_in_full().  Otherwise we at a minimum need to check
for EINTR and EAGAIN, where this is appropriate use xwrite().

Note, the changes to config handling are much larger and handled
in the next patch in the sequence.

Signed-off-by: Andy Whitcroft &lt;apw@shadowen.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Merge branch 'sp/mmap'</title>
<updated>2007-01-07T08:12:47Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2007-01-07T08:12:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=cf2999eb4cbe39d5a40add574be9e5c019df758b'/>
<id>urn:sha1:cf2999eb4cbe39d5a40add574be9e5c019df758b</id>
<content type='text'>
* sp/mmap: (27 commits)
  Spell default packedgitlimit slightly differently
  Increase packedGit{Limit,WindowSize} on 64 bit systems.
  Update packedGit config option documentation.
  mmap: set FD_CLOEXEC for file descriptors we keep open for mmap()
  pack-objects: fix use of use_pack().
  Fix random segfaults in pack-objects.
  Cleanup read_cache_from error handling.
  Replace mmap with xmmap, better handling MAP_FAILED.
  Release pack windows before reporting out of memory.
  Default core.packdGitWindowSize to 1 MiB if NO_MMAP.
  Test suite for sliding window mmap implementation.
  Create pack_report() as a debugging aid.
  Support unmapping windows on 'temporary' packfiles.
  Improve error message when packfile mmap fails.
  Ensure core.packedGitWindowSize cannot be less than 2 pages.
  Load core configuration in git-verify-pack.
  Fully activate the sliding window pack access.
  Unmap individual windows rather than entire files.
  Document why header parsing won't exceed a window.
  Loop over pack_windows when inflating/accessing data.
  ...

Conflicts:

	cache.h
	pack-check.c
</content>
</entry>
<entry>
<title>diff-index --cached --raw: show tree entry on the LHS for unmerged entries.</title>
<updated>2007-01-07T06:57:42Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2007-01-05T09:25:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e9c8409900fc84cd7721117c98dfe01acd535aa2'/>
<id>urn:sha1:e9c8409900fc84cd7721117c98dfe01acd535aa2</id>
<content type='text'>
This updates the way diffcore represents an unmerged pair
somewhat.  It used to be that entries with mode=0 on both sides
were used to represent an unmerged pair, but now it has an
explicit flag.  This is to allow diff-index --cached to report
the entry from the tree when the path is unmerged in the index.

This is used in updating "git reset &lt;tree&gt; -- &lt;path&gt;" to restore
absense of the path in the index from the tree.

Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Replace mmap with xmmap, better handling MAP_FAILED.</title>
<updated>2006-12-29T19:36:45Z</updated>
<author>
<name>Shawn O. Pearce</name>
<email>spearce@spearce.org</email>
</author>
<published>2006-12-24T05:47:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=c4712e4553f13d87d655325a57538f299402d457'/>
<id>urn:sha1:c4712e4553f13d87d655325a57538f299402d457</id>
<content type='text'>
In some cases we did not even bother to check the return value of
mmap() and just assume it worked.  This is bad, because if we are
out of virtual address space the kernel returned MAP_FAILED and we
would attempt to dereference that address, segfaulting without any
real error output to the user.

We are replacing all calls to mmap() with xmmap() and moving all
MAP_FAILED checking into that single location.  If a mmap call
fails we try to release enough least-recently-used pack windows
to possibly succeed, then retry the mmap() attempt.  If we cannot
mmap even after releasing pack memory then we die() as none of our
callers have any reasonable recovery strategy for a failed mmap.

Signed-off-by: Shawn O. Pearce &lt;spearce@spearce.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Merge branch 'maint'</title>
<updated>2006-12-22T06:56:04Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2006-12-22T06:56:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=27e4dd8de76bdd60c88003e0f27cee8ad26c5cd6'/>
<id>urn:sha1:27e4dd8de76bdd60c88003e0f27cee8ad26c5cd6</id>
<content type='text'>
* maint:
  diff --check: fix off by one error
  spurious .sp in manpages
</content>
</entry>
<entry>
<title>diff --check: fix off by one error</title>
<updated>2006-12-22T04:31:14Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>Johannes.Schindelin@gmx.de</email>
</author>
<published>2006-12-22T02:20:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e6d40d65df07059fc655fabe62fa5b575ead7815'/>
<id>urn:sha1:e6d40d65df07059fc655fabe62fa5b575ead7815</id>
<content type='text'>
When parsing the diff line starting with '@@', the line number of the
'+' file is parsed. For the subsequent line parses, the line number
should therefore be incremented after the parse, not before it.

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>simplify inclusion of system header files.</title>
<updated>2006-12-20T17:51:35Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2006-12-19T22:34:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=85023577a8f4b540aa64aa37f6f44578c0c305a3'/>
<id>urn:sha1:85023577a8f4b540aa64aa37f6f44578c0c305a3</id>
<content type='text'>
This is a mechanical clean-up of the way *.c files include
system header files.

 (1) sources under compat/, platform sha-1 implementations, and
     xdelta code are exempt from the following rules;

 (2) the first #include must be "git-compat-util.h" or one of
     our own header file that includes it first (e.g. config.h,
     builtin.h, pkt-line.h);

 (3) system headers that are included in "git-compat-util.h"
     need not be included in individual C source files.

 (4) "git-compat-util.h" does not have to include subsystem
     specific header files (e.g. expat.h).

Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>fix populate-filespec</title>
<updated>2006-12-20T05:33:24Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2006-12-20T02:26:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=5caf92322303a0942e0cee5a93cb24f2d8d44022'/>
<id>urn:sha1:5caf92322303a0942e0cee5a93cb24f2d8d44022</id>
<content type='text'>
I hand munged the original patch when committing 1510fea78, and
screwed up the conversion.

Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>make commit message a little more consistent and conforting</title>
<updated>2006-12-16T06:29:54Z</updated>
<author>
<name>Nicolas Pitre</name>
<email>nico@cam.org</email>
</author>
<published>2006-12-15T04:15:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ebd124c6783da5e064963611ee17741cd173f6b5'/>
<id>urn:sha1:ebd124c6783da5e064963611ee17741cd173f6b5</id>
<content type='text'>
It is nicer to let the user know when a commit succeeded all the time,
not only the first time.  Also the commit sha1 is much more useful than
the tree sha1 in this case.

This patch also introduces a -q switch to supress this message as well
as the summary of created/deleted files.

Signed-off-by: Nicolas Pitre &lt;nico@cam.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Avoid accessing a slow working copy during diffcore operations.</title>
<updated>2006-12-16T06:11:19Z</updated>
<author>
<name>Shawn O. Pearce</name>
<email>spearce@spearce.org</email>
</author>
<published>2006-12-14T11:15:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=1510fea781cb0517eeba8c378964f7bc4f9577ab'/>
<id>urn:sha1:1510fea781cb0517eeba8c378964f7bc4f9577ab</id>
<content type='text'>
The Cygwin folks have done a fine job at creating a POSIX layer
on Windows That Just Works(tm).  However it comes with a penalty;
accessing files in the working tree by way of stat/open/mmap can
be slower for diffcore than inflating the data from a blob which
is stored in a packfile.

This performance problem is especially an issue in merge-recursive
when dealing with nearly 7000 added files, as we are loading
each file's content from the working directory to perform rename
detection.  I have literally seen (and sadly watched) paint dry in
less time than it takes for merge-recursive to finish such a merge.
On the other hand this very same merge runs very fast on Solaris.

If Git is compiled with NO_FAST_WORKING_DIRECTORY set then we will
avoid looking at the working directory when the blob in question
is available within a packfile and the caller doesn't need the data
unpacked into a temporary file.

We don't use loose objects as they have the same open/mmap/close
costs as the working directory file access, but have the additional
CPU overhead of needing to inflate the content before use.  So it
is still faster to use the working tree file over the loose object.

If the caller needs the file data unpacked into a temporary file
its likely because they are going to call an external diff program,
passing the file as a parameter.  In this case reusing the working
tree file will be faster as we don't need to inflate the data and
write it out to a temporary file.

The NO_FAST_WORKING_DIRECTORY feature is enabled by default on
Cygwin, as that is the platform which currently appears to benefit
the most from this option.

Signed-off-by: Shawn O. Pearce &lt;spearce@spearce.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
</feed>
