[OSM-dev] renderd multithreading question

Jon Burgess jburgess777 at googlemail.com
Fri Nov 13 23:06:37 GMT 2009


On Fri, 2009-11-13 at 23:42 +0100, Frederik Ramm wrote:
> Hi,
> 
>      I'm running the C version of renderd on an 8-core machine with 
> num_threads configured to 8. (PostGIS is on another machine so renderd 
> has the CPU to itself.) I had assumed that it would somehow magically 
> manage its queue and have up to 8 threads render tiles when there is 
> demand, and make sure to render high priority requests first etc.

It will that.

> However I find that if I request a large number of tiles through 
> render_list, only one CPU is used to produce them sequentially.

That is the fault of render_list. It only submits one request at a time
and waits for it to complete before moving on.

The render_old code was recently upgraded to submit multiple requests in
parallel. The same changes could be done for render_list.

> Would I simply have to run 8 parallel render_list processes to achieve 
> the desired result? And if, during such a scenario, another 4 mod_tile 
> processes connect to renderd and have high priority requests, would they 
> still be given priority over the ongoing bulk rendering?

Yes, the mod_tile RenderPrio requests should get rendered in preference
to the render_list requests. It might make sense to update render_list
to submit cmdRenderBulk requests.

	Jon






More information about the dev mailing list