##// END OF EJS Templates
rhg: stop manifest traversal when no more files are needed...
rhg: stop manifest traversal when no more files are needed Stopping the traversal early can skip a significant part of the manifest traversal, to avoid some of its cost. The worst-case benchmarks are favorable, as well. Running [hg cat] on the last file in the manifest of a large repo, I'm seeing a ~4ms improvement (150ms -> 146ms), so this time is now almost indistinguishable from the baseline ("brute force") implementation. Running [hg cat] on ~220 files together with the last file of the repo is further improved by ~5ms or so. I suspect the raw performance improvements are caused by splitting the manifest search and the file data access into separate phases, instead of interleaving them. Differential Revision: https://phab.mercurial-scm.org/D11616

File last commit:

r38982:f9a98075 default
r49039:0cc69017 default
Show More
map-cmdline.status
21 lines | 972 B | text/plain | TextLexer
Jordi Gutiérrez Hermoso
log: add a status template...
r25006 %include map-cmdline.default
Yuya Nishihara
templater: load template fragments from [templates] section in map file...
r34715 [templates]
Jordi Gutiérrez Hermoso
log: add a status template...
r25006 # Override base templates
Yuya Nishihara
templates: rename "user" to "luser" defined in default map file (API)...
r38982 changeset = '{cset}{branches}{bookmarks}{tags}{parents}{luser}{ldate}{summary}{lfiles}\n'
changeset_verbose = '{cset}{branches}{bookmarks}{tags}{parents}{luser}{ldate}{description}{lfiles}\n'
changeset_debug = '{fullcset}{branches}{bookmarks}{tags}{lphase}{parents}{manifest}{luser}{ldate}{extras}{description}{lfiles}\n'
Jordi Gutiérrez Hermoso
log: add a status template...
r25006
# Override the file templates
lfiles = '{if(files,
label('ui.note log.files',
Yuya Nishihara
log: fix status template to list copy source per dest (issue5155)...
r29000 'files:\n'))}{lfile_mods}{lfile_adds}{lfile_dels}'
Jordi Gutiérrez Hermoso
log: add a status template...
r25006
Yuya Nishihara
log: fix status template to list copy source per dest (issue5155)...
r29000 lfile_adds = '{file_adds % "{lfile_add}{lfile_src}"}'
lfile_mods = '{file_mods % "{lfile_mod}{lfile_src}"}'
Jordi Gutiérrez Hermoso
log: add a status template...
r25006 lfile_add = '{label("status.added", "A {file}\n")}'
Yuya Nishihara
log: fix status template to list copy source per dest (issue5155)...
r29000 lfile_mod = '{label("status.modified", "M {file}\n")}'
lfile_src = '{ifcontains(file, file_copies_switch,
label("status.copied", " {get(file_copies_switch, file)}\n"))}'
Jordi Gutiérrez Hermoso
log: add a status template...
r25006
lfile_dels = '{file_dels % "{label('status.removed', 'R {file}\n')}"}'