marmoute added a comment.
(grmlml, realising that I forgot to do the dual "submit" for my comment. It is 2019, why is Phabricator still not fixing this…) INLINE COMMENTS > indygreg wrote in context.py:503 > Before I accept more of this series, I'd like others to think about the > potential alternative solution of passing in or storing a reference to the > changelog on `basectx`/`changectx`. The reason is that a lot of methods are > calling `repo.changelog` and this can be expensive. I suspect we'd get a > handful of random performance wins if we cached the changelog instance on > each `basectx`. We also wouldn't need to litter the code with a bunch of > conditional `repo.unfiltered()` calls since we'd already have an appropriate > changelog instance stored in the instance. > > Thoughts? We woul still need the conditional instance since the maybe_filtered logic only apply to some of the changectx call. (eg: children need to go through filtering). An overall better/more reobust solution to make the filtering lazier at the changelog level and to most the fastpath logic there. It would be more contained and more robust. However, I decided I digged the rabbit hole enough for now and this other approach can be looked at later. REPOSITORY rHG Mercurial CHANGES SINCE LAST ACTION https://phab.mercurial-scm.org/D7483/new/ REVISION DETAIL https://phab.mercurial-scm.org/D7483 To: marmoute, #hg-reviewers Cc: martinvonz, indygreg, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel