<feed xmlns='http://www.w3.org/2005/Atom'>
<title>apt/apt-pkg/pkgcache.cc, branch 1.1_exp16</title>
<subtitle>Debians commandline package manager</subtitle>
<id>https://git.kalnischkies.de/apt/atom?h=1.1_exp16</id>
<link rel='self' href='https://git.kalnischkies.de/apt/atom?h=1.1_exp16'/>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/'/>
<updated>2015-09-14T13:22:18Z</updated>
<entry>
<title>remove incorrect optimization branches</title>
<updated>2015-09-14T13:22:18Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-09-08T11:58:55Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=8fec289ad8a2c42350c24d5c97b0f104fbbea176'/>
<id>urn:sha1:8fec289ad8a2c42350c24d5c97b0f104fbbea176</id>
<content type='text'>
These assumptions were once true, but they aren't anymore, so what is
supposed to be a speed up is effectively a slowdown [not that it would
be noticible].

Usage of SingleArchFindPkg was nuked in a stable update already as the
included assumption was actually harmful btw, which is why we should get
right of other 'non-harmful' but still untrue assumptions while we can.

Git-Dch: Ignore
</content>
</entry>
<entry>
<title>implement dpkgs vision of interpreting pkg:&lt;arch&gt; dependencies</title>
<updated>2015-09-14T13:22:18Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-09-06T11:32:07Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=3addaba1ff6fe27cc96af5c2d345ee039c2bffec'/>
<id>urn:sha1:3addaba1ff6fe27cc96af5c2d345ee039c2bffec</id>
<content type='text'>
How the Multi-Arch field and pkg:&lt;arch&gt; dependencies interact was
discussed at DebConf15 in the "MultiArch BoF". dpkg and apt (among other
tools like dose) had a different interpretation in certain scenarios
which we resolved by agreeing on dpkg view – and this commit realizes
this agreement in code.

As was the case so far libapt sticks to the idea of trying to hide
MultiArch as much as possible from individual frontends and instead
translates it to good old SingleArch. There are certainly situations
which can be improved in frontends if they know that MultiArch is upon
them, but these are improvements – not necessary changes needed
to unbreak a frontend.

The implementation idea is simple: If we parse a dependency on foo:amd64
the dependency is formed on a package 'foo:amd64' of arch 'any'. This
package is provided by package 'foo' of arch 'amd64', but not by 'foo'
of arch 'i386'. Both of those foo packages provide each other through
(assuming foo is M-A:foreign) to allow a dependency on 'foo' to be
satisfied by either foo of amd64 or i386. Packages can also declare to
provide 'foo:amd64' which is translated to providing 'foo:amd64:any' as
well.

This indirection over provides was chosen as the alternative would be to
teach dependency resolvers how to deal with architecture specific
dependencies – which violates the design idea of avoiding resolver
changes, especially as architecture-specific dependencies are a
cornercase with quite a few subtil rules. Handling it all over versioned
provides as we already did for M-A in general seems much simpler as it
just works for them.

This switch to :any has actually a "surprising" benefit as well: Even
frontends showing a package name via .Name() [which doesn't show the
architecture] will display the "architecture" for dependencies in which
it was explicitely requested, while we will not show the 'strange' :any
arch in FullName(true) [= pretty-print] either. Before you had to
specialcase these and by default you wouldn't get these details shown.

The only identifiable disadvantage is that this complicates error
reporting and handling. apt-get's ShowBroken has existing problems with
virtual packages [it just shows the name without any reason], so that
has to be worked on eventually. The other case is that detecting if a
package is completely unknown or if it was at least referenced somewhere
needs to acount for this "split" – not that it makes a practical
difference which error is shown… but its one of the improvements
possible.
</content>
</entry>
<entry>
<title>store ':any' pseudo-packages with 'any' as architecture</title>
<updated>2015-09-14T13:22:18Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-09-05T10:58:04Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=f6ce7ffce526432a855166074332f97b37ad98db'/>
<id>urn:sha1:f6ce7ffce526432a855166074332f97b37ad98db</id>
<content type='text'>
Previously we had python:any:amd64, python:any:i386, … in the cache and
the dependencies of an amd64 package would be on python:any:amd64, of an
i386 on python:any:i386 and so on. That seems like a relatively
pointless endeavor given that they will all be provided by the same
packages and therefore also a waste of space.

Git-Dch: Ignore
</content>
</entry>
<entry>
<title>Cleanup includes after running iwyu</title>
<updated>2015-08-17T10:01:45Z</updated>
<author>
<name>Michael Vogt</name>
<email>mvo@debian.org</email>
</author>
<published>2015-08-17T10:01:45Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=88a8975f156e452d9f3ebe76822b236e8962ebba'/>
<id>urn:sha1:88a8975f156e452d9f3ebe76822b236e8962ebba</id>
<content type='text'>
</content>
</entry>
<entry>
<title>parse packages from all architectures into the cache</title>
<updated>2015-08-10T15:27:59Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-20T10:32:46Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=7f8c0eed6983db7b8959f1498fc8bc80c98d719e'/>
<id>urn:sha1:7f8c0eed6983db7b8959f1498fc8bc80c98d719e</id>
<content type='text'>
Now that we can dynamically create dependencies and provides as needed
rather than requiring to know with which architectures we will deal
before running we can allow the listparser to parse all records rather
than skipping records of "unknown" architectures.

This can e.g. happen if a user has foreign architecture packages in his
status file without dpkg knowing about this architecture (or apt
configured in this way).

A sideeffect is that now arch:all packages are (correctly) recorded as
available from any Packages file, not just from the native one – which
has its downsides for the resolver as mixed-arch source packages can
appear in different architectures at different times, but that is the
problem of the resolver and dealing with it in the parser is at best a
hack (and also depends on a helpful repository).

Another sideeffect is that his allows :none packages to appear in
Packages files again as we don't do any kind of checks now, but given
that they aren't really supported (anymore) by anyone we can live with
that.
</content>
</entry>
<entry>
<title>hide implicit deps in apt-cache again by default</title>
<updated>2015-08-10T15:27:58Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-16T09:15:25Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=8c7af4d4c95d0423fbd0f3baa979792504f4f45f'/>
<id>urn:sha1:8c7af4d4c95d0423fbd0f3baa979792504f4f45f</id>
<content type='text'>
Before MultiArch implicits weren't a thing, so they were hidden by
default by definition. Adding them for MultiArch solved many problems,
but having no reliable way of detecting which dependency (and provides)
is implicit or not causes problems everytime we want to output
dependencies without confusing our observers with unneeded
implementation details.

The really notworthy point here is actually that we keep now a better
record of how a dependency came to be so that we can later reason about
it more easily, but that is hidden so deep down in the library internals
that change is more the problems it solves than the change itself.
</content>
</entry>
<entry>
<title>use a smaller type for flags storage in the cache</title>
<updated>2015-08-10T15:27:58Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-15T12:36:16Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=dfe66c72ffc010e019e96b35154e1ad4ab506a6e'/>
<id>urn:sha1:dfe66c72ffc010e019e96b35154e1ad4ab506a6e</id>
<content type='text'>
We store very few flags in the cache, so keeping storage space for 8 is
enough for all of them and still leaves a few unused bits remaining for
future extensions without wasting bytes for nothing.

Git-Dch: Ignore
</content>
</entry>
<entry>
<title>remove the compatibility markers for 4.13 abi</title>
<updated>2015-08-10T15:27:58Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-15T11:21:21Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=4dc77823d360158d6870a5710cc8c17064f1308f'/>
<id>urn:sha1:4dc77823d360158d6870a5710cc8c17064f1308f</id>
<content type='text'>
We aren't and we will not be really compatible again with the previous
stable abi, so lets drop these markers (which never made it into a
released version) for good as they have outlived their intend already.

Git-Dch: Ignore
</content>
</entry>
<entry>
<title>split-up Dependency struct</title>
<updated>2015-08-10T15:27:18Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-13T14:28:21Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=71c9e95b223517b5f51c4627f6ad4cce8af0d901'/>
<id>urn:sha1:71c9e95b223517b5f51c4627f6ad4cce8af0d901</id>
<content type='text'>
Having dependency data separated from the link between version/package
and the dependency allows use to work on sharing the depdency data a bit
as it turns out that many dependencies are in fact duplicates. How many
are duplicates various heavily with the sources configured, but for a
single Debian release the ballpark is 2 duplicates for each dependency
already (e.g. libc6 counts 18410 dependencies, but only 45 unique). Add
more releases and the duplicates count only rises to get ~6 for 3
releases. For each architecture a user has configured which given the
shear number of dependencies amounts to MBs of duplication.

We can cut down on this number, but pay a heavy price for it: In my
many releases(3) + architectures(3) test we have a 10% (~ 0.5 sec)
increase in cache creationtime, but also 10% less cachesize (~ 10 MB).

Further work is needed to rip the whole benefits from this through, so
this is just the start.

Git-Dch: Ignore
</content>
</entry>
<entry>
<title>bunch of micro-optimizations for depcache</title>
<updated>2015-08-10T15:27:18Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2015-07-13T10:47:05Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=fd23676e809b7fa87ae138cc22d2c683d212950e'/>
<id>urn:sha1:fd23676e809b7fa87ae138cc22d2c683d212950e</id>
<content type='text'>
DepCache functions are called a lot, so if we can squeeze some drops out
of them for free we should do so. Takes also the opportunity to remove
some whitespace errors from these functions.

Git-Dch: Ignore
</content>
</entry>
</feed>
