Julian Andres Klode left as an exercise for the reader: > Proposing to replace something with code that is not (yet) available > is not really helpful. The code you have linked to above seems to be Just trying to get things moving in parallel. I expect to be feature-equivalent with apt-show-versions by the end of the week. > a rather limited parser that can extract some parts from packages > files (namely, names and versions). It is in no way a replacement > for apt-show-versions, at least not for now. One thing you mention is already addressed by commit 1b4d7846 from a few minutes ago, but agreed -- at this moment, it's in no way a replacement. It's coming along quite rapidly, though; https://github.com/dankamongmen/raptorial/blob/master/src/bin/rapt-show-versions.c was introduced, for instance, since I sent my first mail. Also, the fairly limited (this is an accurate assessment) parser is successfully multithreaded, and evidences linear speedup across cpus provided sufficiently fast disk; from the perspective of performance, the existing implementation is limited :). But yes, feature set equivalence has not yet been attained. > We could probably easily rewrite apt-show-versions in C++ using > libapt-pkg and get an immensive speed up this way, as we'd be > able to utilise APT's cache (the cache should have all required > information in it anyway). That could very well be the best choice for Debian right now, and I encourage you to do so. As I noted, required time dropped by 80%+ using only a single core, so you're almost certainly correct. That said, to get peak perf on multicore machines, you'll need to thread, but except on fairly flow cpus with fairly high physical parallelism, you won't win much from that. If you take that route, feel free to forget about this project for some time, as general APT replacement will take several months. Hack on! --nick -- nick black http://www.sprezzatech.com -- unix and hpc consulting to make an apple pie from scratch, you need first invent a universe.
Description: Digital signature