[OSM-talk] Is gosmore broken with the latest planet file?

Petter Reinholdtsen pere at hungry.com
Sun Aug 5 17:01:00 BST 2007


[Nic Roets]
> I wouldn't be able to investigate the problem soon, but if I have to
> make a guess, it would have to be that the hardcoded constants need
> adjustment after the planet file has grown.

Right.  Sounds like something should give a better error message
instead of crashing with a bogus free(). :)

> If you have >= 1GB RAM, you can try this:
> 
> line 38:
> #define MAX_NODES 30100800
> #define MAX_SEGMENTS 30100800
> #define MAX_NAMED_NODES 150000
> line 891 :
>   wayBuildType *w = (wayBuildType *) calloc (sizeof (*w), 3000000);

Right.  I foudn the three top ones, but not the one deep down in the
code.  What is the last value, and is it an idea to move it up among
the other constants?

Increasing the values helped.  Now the program completed without
crashing, and draw the updated map.  Should I increase the values in
svn?  I just add *2 to the values, but suspect some smaller value
would be a better choice.

Is there some way to get gosmore to use less memory?  It is getting
harder and harder to find a machine to run it on. :)

Happy hacking,
-- 
Petter Reinholdtsen




More information about the talk mailing list