[Tile-serving] [osm2pgsql] node-cache: fix prefetching (#353)

Sarah Hoffmann notifications at github.com
Tue May 26 18:09:08 UTC 2015


>      for (size_t i = 0; i < nds.size(); ++i) {
>          /* Check cache first */
> -        if (ram_cache && (ram_cache->get(&out[i], nds[i]) != 0)) {
> +        if (!ram_cache || (ram_cache->get(&out[i], nds[i]) == 0)) {

So ti turns out, I got the semantics of ram_cache->get() wrong. It actually returns 0 when it finds a node. (Fix will follow in a bit.) The consequence is that all nodes are looked up in the flat node store. If that makes the memory hogging worse, the flat node store must be the culprit. Investigating.

---
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/osm2pgsql/pull/353/files#r31062124
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/tile-serving/attachments/20150526/e4dbeb0c/attachment.html>


More information about the Tile-serving mailing list