sapling/eden/scm/edenscm
Jun Wu a16c1c3e28 changelog2: preserve laziness of 'ancestors'
Summary:
This is important for performance. Especially, `copies.py` uses it, and a
non-lazy `ancestors` would slow down common operations like rebase or histedit
or `log -p` because they all use `copies.py`.

Before, `log -pr. -T. --profile>/dev/null`:

```
  2859        \ pathcopies                      copies.py:234
  2858         | _forwardcopies                 copies.py:202
  2858         | _committedforwardcopies        copies.py:166
    11          \ computeforwardmissing         remotefilelog/__init__.py:508
     3            \ _computeforwardmissing      copies.py:156
     7            \ prefetch                    fileserverclient.py:237
     5             | __get__                    util.py:982
     5             | fileslog                   shallowrepo.py:47
     5             | __init__                   remotefilelog.py:465
     5             | makeruststore              remotefilelog.py:519
* 2836          \ ancestors                     changelog2.py:462
     3        \ difffn                          patch.py:2696
     3         | trydiff                        remotefilelog/__init__.py:667
     3         | prefetch                       fileserverclient.py:237
Total time: 3114 ms
```

After:

```
   11        \ pathcopies                       copies.py:234
   10         | _forwardcopies                  copies.py:202
   10         | _committedforwardcopies         copies.py:166
   10         | computeforwardmissing           remotefilelog/__init__.py:508
    3          \ _computeforwardmissing         copies.py:156
    7          \ prefetch                       fileserverclient.py:237
    5           | __get__                       util.py:982
    5           | fileslog                      shallowrepo.py:47
    5           | __init__                      remotefilelog.py:465
    5           | makeruststore                 remotefilelog.py:519
    3        \ difffn                           patch.py:2696
    3         | trydiff                         remotefilelog/__init__.py:667
    2         | prefetch                        fileserverclient.py:237
```

Reviewed By: sfilipco

Differential Revision: D23036057

fbshipit-source-id: 815cb167d38d0e5d1640ea6156b0891c72253933
2020-08-21 13:00:45 -07:00
..
hgdemandimport demanedimportpy3: fix demandimport for ipdb 2020-06-22 08:59:14 -07:00
hgext commands: add debugchangelog command 2020-08-21 13:00:45 -07:00
mercurial changelog2: preserve laziness of 'ancestors' 2020-08-21 13:00:45 -07:00
__init__.py start adding type annotations for the cext code 2020-02-21 13:54:19 -08:00
__main__.py edenscm: add a main module 2020-01-30 18:09:14 -08:00
traceimport.py Replace whitelist/blacklist term 2020-06-15 15:01:19 -07:00