Hi, been playing with flightgear a bit, trying to get it to page tiles on more than one thread. The patch does 2 things:
First, the database pager respects the environment variable to set DB pager threads' priority. It makes quite a difference in minimum and average frame rates. Second, viewerbase is helpfully (?!) setting the affinity of all DB pager threads' to CPU1 (the 2nd CPU). The graphics thread is ALSO affinity'd to this cpu, resulting in the hilarious situation where only that cpu is used (on a quad core). I commented the line and it works as expected, no idea how affinity is gonna help here. I start 8 threads on a quad-core, with MIN priority, works nicely. Haven't checked what is the minimum number of threads needed for 100% utilization, but i guess it depends on the system (#cores, IO speed, V-sync, hot disk caches, ...) and varies wildly. 8 threads give me 95+% CPU utilization and with the priority patch 50+fps while eating thru tiles like crazy :) Thank you! Cheers, Yon ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=26228#26228 Attachments: http://forum.openscenegraph.org//files/threadingpatch_140.txt _______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
