Show More
@@ -567,7 +567,7 b' def perfmanifest(ui, repo, rev, **opts):' | |||||
567 | t = ctx.manifestnode() |
|
567 | t = ctx.manifestnode() | |
568 | def d(): |
|
568 | def d(): | |
569 | repo.manifest.clearcaches() |
|
569 | repo.manifest.clearcaches() | |
570 |
repo.manifest.read( |
|
570 | repo.manifestlog[t].read() | |
571 | timer(d) |
|
571 | timer(d) | |
572 | fm.end() |
|
572 | fm.end() | |
573 |
|
573 |
@@ -1660,7 +1660,7 b' class queue(object):' | |||||
1660 | # caching against the next repo.status call |
|
1660 | # caching against the next repo.status call | |
1661 | mm, aa, dd = repo.status(patchparent, top)[:3] |
|
1661 | mm, aa, dd = repo.status(patchparent, top)[:3] | |
1662 | changes = repo.changelog.read(top) |
|
1662 | changes = repo.changelog.read(top) | |
1663 |
man = repo.manifest |
|
1663 | man = repo.manifestlog[changes[0]].read() | |
1664 | aaa = aa[:] |
|
1664 | aaa = aa[:] | |
1665 | matchfn = scmutil.match(repo[None], pats, opts) |
|
1665 | matchfn = scmutil.match(repo[None], pats, opts) | |
1666 | # in short mode, we only diff the files included in the |
|
1666 | # in short mode, we only diff the files included in the |
@@ -1594,33 +1594,6 b' class manifest(manifestrevlog):' | |||||
1594 | self._dirlogcache) |
|
1594 | self._dirlogcache) | |
1595 | return self._dirlogcache[dir] |
|
1595 | return self._dirlogcache[dir] | |
1596 |
|
1596 | |||
1597 | def read(self, node): |
|
|||
1598 | if node == revlog.nullid: |
|
|||
1599 | return self._newmanifest() # don't upset local cache |
|
|||
1600 | if node in self._mancache: |
|
|||
1601 | cached = self._mancache[node] |
|
|||
1602 | if (isinstance(cached, manifestctx) or |
|
|||
1603 | isinstance(cached, treemanifestctx)): |
|
|||
1604 | cached = cached.read() |
|
|||
1605 | return cached |
|
|||
1606 | if self._treeondisk: |
|
|||
1607 | def gettext(): |
|
|||
1608 | return self.revision(node) |
|
|||
1609 | def readsubtree(dir, subm): |
|
|||
1610 | return self.dirlog(dir).read(subm) |
|
|||
1611 | m = self._newmanifest() |
|
|||
1612 | m.read(gettext, readsubtree) |
|
|||
1613 | m.setnode(node) |
|
|||
1614 | arraytext = None |
|
|||
1615 | else: |
|
|||
1616 | text = self.revision(node) |
|
|||
1617 | m = self._newmanifest(text) |
|
|||
1618 | arraytext = array.array('c', text) |
|
|||
1619 | self._mancache[node] = m |
|
|||
1620 | if arraytext is not None: |
|
|||
1621 | self.fulltextcache[node] = arraytext |
|
|||
1622 | return m |
|
|||
1623 |
|
||||
1624 | def clearcaches(self): |
|
1597 | def clearcaches(self): | |
1625 | super(manifest, self).clearcaches() |
|
1598 | super(manifest, self).clearcaches() | |
1626 | self._mancache.clear() |
|
1599 | self._mancache.clear() |
General Comments 0
You need to be logged in to leave comments.
Login now