1. 02 8月, 2008 10 次提交
  2. 26 7月, 2008 4 次提交
  3. 24 7月, 2008 1 次提交
  4. 21 7月, 2008 1 次提交
    • J
      fix usage string for git grep · 2d9c5725
      Jonathan Nieder 提交于
      Without this patch, git-grep gives confusing usage information:
      
      	$ git grep --confused
      	usage: git grep <option>* <rev>* [-e] <pattern> [<path>...]
      	$ git grep HEAD pattern
      	fatal: ambiguous argument 'pattern': unknown revision or path no
      	t in the working tree.
      	Use '--' to separate paths from revisions
      
      So put <pattern> before the <rev>s, in accordance with actual correct
      usage.  While we're changing the usage string, we might as well include
      the "--" separating revisions and paths, too.
      Signed-off-by: NJonathan Nieder <jrnieder@uchicago.edu>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      2d9c5725
  5. 20 7月, 2008 3 次提交
  6. 19 7月, 2008 1 次提交
    • J
      Merge branch 'sp/maint-index-pack' into maint · fcf74dbf
      Junio C Hamano 提交于
      * sp/maint-index-pack:
        index-pack: Honor core.deltaBaseCacheLimit when resolving deltas
        index-pack: Track the object_entry that creates each base_data
        index-pack: Chain the struct base_data on the stack for traversal
        index-pack: Refactor base arguments of resolve_delta into a struct
      fcf74dbf
  7. 18 7月, 2008 3 次提交
  8. 17 7月, 2008 12 次提交
  9. 16 7月, 2008 2 次提交
  10. 15 7月, 2008 3 次提交
    • S
      index-pack: Honor core.deltaBaseCacheLimit when resolving deltas · 92392b4a
      Shawn O. Pearce 提交于
      If we are trying to resolve deltas for a long delta chain composed
      of multi-megabyte objects we can easily run into requiring 500M+
      of memory to hold each object in the chain on the call stack while
      we recurse into the dependent objects and resolve them.
      
      We now use a simple delta cache that discards objects near the
      bottom of the call stack first, as they are the most least recently
      used objects in this current delta chain.  If we recurse out of a
      chain we may find the base object is no longer available, as it was
      free'd to keep memory under the deltaBaseCacheLimit.  In such cases
      we must unpack the base object again, which will require recursing
      back to the root of the top of the delta chain as we released that
      root first.
      
      The astute reader will probably realize that we can still exceed
      the delta base cache limit, but this happens only if the most
      recent base plus the delta plus the inflated dependent sum up to
      more than the base cache limit.  Due to the way patch_delta is
      currently implemented we cannot operate in less memory anyway.
      Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      92392b4a
    • S
      index-pack: Track the object_entry that creates each base_data · 03993e13
      Shawn O. Pearce 提交于
      If we free the data stored within a base_data we need the struct
      object_entry to get the data back again for use with another dependent
      delta.  Storing the object_entry* in base_data makes it simple to call
      get_data_from_pack() to recover the compressed information.
      
      This however means that we must add the missing base object to the end of
      our packfile prior to calling resolve_delta() on each of the dependent
      deltas.  Adding the base first ensures we can read the base back from the
      pack we are indexing, as if it had been included by the remote side.
      Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      03993e13
    • S
      index-pack: Chain the struct base_data on the stack for traversal · 4a438cab
      Shawn O. Pearce 提交于
      We need to release earlier inflated base objects when memory gets
      low, which means we need to be able to walk up or down the stack
      to locate the objects we want to release, and free their data.
      
      The new link/unlink routines allow inserting and removing the struct
      base_data during recursion inside resolve_delta, and the global
      base_cache gives us the head of the chain (bottom of the stack)
      so we can traverse it.
      Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      4a438cab