Skip to content
Snippets Groups Projects
  1. Jul 31, 2018
    • Martijn Pieters's avatar
      manifest: persist the manifestfulltext cache · 0a57945aaf7f
      Martijn Pieters authored
      Reconstructing the manifest from the revlog takes time, so much so that there
      already is a LRU cache to avoid having to load a manifest multiple times.
      
      This patch persists that LRU cache in the .hg/cache directory, so we can re-use
      this cache across hg commands. Commit benchmark (run on Macos 10.13 on a
      2017-model Macbook Pro with Core i7 2.9GHz and flash drive), testing without
      and with patch run 5 times, baseline is r2a227782e754:
      
      * committing to an existing file, against the mozilla-central repository.
        Baseline real time average 1.9692, with patch 1.3786.
      
      A new debugcommand "hg debugmanifestfulltextcache" lets you inspect the cache,
      clear it, or add specific manifest nodeids to it. When calling
      repo.updatecaches(), the manifest(s) for the working copy parents are added to
      the cache.
      
      The hg perfmanifest command has an additional --clear-disk switch to clear this
      cache when testing manifest loading performance.
      
      Using this command to test performance on the firefox repository for revision
      f947d902ed91, whose manifest has a delta chain length of 60540, we see:
      
      $ hg perfmanifest f947d902ed91 --clear-disk
      ! wall 0.972253 comb 0.970000 user 0.850000 sys 0.120000 (best of 10)
      $ hg debugmanifestfulltextcache -a `hg log --debug -r f947d902ed91 | grep manifest | cut -d: -f3`
      Cache contains 1 manifest entries, in order of most to least recent:
      id: 0294517df4aad07c70701db43bc7ff24c3ce7dbc, size 25.6 MB
      Total cache data size 25.6 MB, on-disk 0 bytes
      $ hg perfmanifest f947d902ed91
      ! wall 0.036748 comb 0.040000 user 0.020000 sys 0.020000 (best of 100)
      
      Worst-case scenario: a manifest text loaded from a single delta; in the firefox
      repository manifest node 9a1246ff762e is the chain base for the manifest
      attached to revision f947d902ed91. Loading this from a full cache file is just
      as fast as without the cache; the extra node ids ensure a big full cache:
      
      $ for node in 9a1246ff762e 1a1922c14a3e 54a31d11a36a 0294517df4aa; do
      >   hgd debugmanifestfulltextcache -a $node > /dev/null
      > done
      $ hgd perfmanifest -m 9a1246ff762e
      ! wall 0.077513 comb 0.080000 user 0.030000 sys 0.050000 (best of 100)
      $ hgd perfmanifest -m 9a1246ff762e --clear-disk
      ! wall 0.078547 comb 0.080000 user 0.070000 sys 0.010000 (best of 100)
      0a57945aaf7f
    • Martijn Pieters's avatar
      ddb15a83ae0b
  2. Jul 20, 2018
  3. Jul 16, 2018
  4. Jul 30, 2018
  5. Jul 27, 2018
  6. Jul 20, 2018
  7. Jul 19, 2018
  8. Aug 01, 2018
  9. Jul 31, 2018
    • Gregory Szorc's avatar
      ui: remove commands.status.terse=u from ui.tweakdefaults · fe3ca1e6f786
      Gregory Szorc authored
      commands.status.terse=u can add significant overhead when operating
      on large repositories. Using the Firefox repository:
      
      HGRCPATH= hg --time status
      time: real 1.340 secs (user 0.960+0.000 sys 0.380+0.000)
      
      HGRCPATH= hg --time --config commands.status.terse=u status
      time: real 2.420 secs (user 2.070+0.000 sys 0.360+0.000)
      
      HGRCPATH= hg --time --config extensions.fsmonitor= status
      time: real 0.080 secs (user 0.050+0.010 sys 0.040+0.000)
      
      HGRCPATH= ~/src/hg/hg --time --config extensions.fsmonitor= --config commands.status.terse=u status
      time: real 2.470 secs (user 2.080+0.000 sys 0.390+0.000)
      
      The performance regression - especially when fsmonitor is being
      used - is too much to stomach for the 4.7 release. We've decided
      to remove commands.status.terse=u from ui.tweakdefaults until we
      can improve its performance, hopefully in the 4.8 cycle.
      
      This commit effectively backs out 6acf41bb8d40.
      fe3ca1e6f786
  10. Jul 25, 2018
    • Pulkit Goyal's avatar
      context: safegaurd against 'lx' being passed as file flag in manifest · d558e53cd6b6
      Pulkit Goyal authored
      Subversion can have a file as executable link. When using hgsubversion, we will
      have both islink and isexec True. This will lead to _flags being set to `lx`.
      However, manifest expects flag to be one-byte so it will crash if 'lx' is
      passed. Also it's impossible to have an executable link.
      
      This patch will safegaurd us from having 'lx' being a possible value.
      
      This was authored by Ivan Lezhankin from Yandex.
      
      Differential Revision: https://phab.mercurial-scm.org/D3985
      d558e53cd6b6
  11. Jul 31, 2018
  12. Jul 30, 2018
  13. Jul 29, 2018
  14. Jul 27, 2018
  15. Jul 30, 2018
  16. Jul 31, 2018
  17. Jul 30, 2018
    • Boris Feld's avatar
      clone: process 'lookup' return as an arbitrary symbol · e06a10d3b926
      Boris Feld authored
      In theory, checkout is expected to be a node here because it was returned by
      peer.lookup.
      
      In practice, multiple important extensions (like hg-git, hg-subversion) use
      peers not backed by a mercurial repository where lookup cannot return a node.
      
      Allowing arbitrary symbols is necessary to make these extensions working with
      4.7.
      
      We should probably introduce a new API in Core to have these extensions to
      work without abusing the lookup API. In the meantime, a small change to
      restore compatibility in 4.7 seems in order.
      e06a10d3b926
    • Augie Fackler's avatar
      tests: use inline Python instead of sed to add trailing whitespace · 8623a6c96998
      Augie Fackler authored
      The sed invocation was failing on OS X and FreeBSD. I'm far too lazy
      to diagnose that, so just use some inline Python to fix the build.
      8623a6c96998
    • Augie Fackler's avatar
      context: add missing b prefix · 71d6886d27cf
      Augie Fackler authored
      This fixes
        mercurial/context.py:593: SyntaxError: cannot mix bytes and nonbytes literals (context.py, line 593)
      in Python 3.
      71d6886d27cf
  18. Jul 28, 2018
  19. Jul 30, 2018
  20. Jul 28, 2018
  21. Jul 26, 2018
    • Gregory Szorc's avatar
      gitweb: add link to graph · 0f948d821fe7
      Gregory Szorc authored
      error.tmpl wasn't consistent with other templates in gitweb in
      that it was missing a "graph" link. This commit makes it consistent.
      0f948d821fe7
  22. Jul 25, 2018
  23. Jul 20, 2018
    • Boris Feld's avatar
      config: rename `revlog` section into `storage` · ae17555ef93f
      Boris Feld authored
      The idea was suggested by Gregory Szorc on IRC. It is more generic and seems
      better. It is probably best to rename the section before it ever makes into an
      official (non-rc) release.
      
      The only config option currently in this section have been prefixed with
      `revlog` to clarify it applies to `revlog` related storage.
      ae17555ef93f
  24. Jul 19, 2018
Loading