Hi Robert,
 
I tried running the threads on separate cores last night.  (On the first 2
cpus, which should be the physcial cpus).  This did not help the
performance.  I verified the thread's affinity using the performance
monitor.  The threads were impacting each other.  This tells me there is a
potential thread synchronization problem.
 
I also timed some file loads linux vs. windows on the same hardware (in
seconds):
fileA lnx=13.1, win=37.0
fileB lnx=1.61, win=2.26
fileC lnx=1.20, win=1.60
 
fileA is a file that references a bunch of 200 other files about ~5MB each
fileB is 51.9MB
fileC is 41.2MB 
 
Paging is done more like fileA.  This tells me that if there were a thread
synchronization problem it could be hidden on linux, by its superior file
system.
 

Zach


 

  _____  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield
Sent: Wednesday, March 14, 2007 06:16
To: osg users
Subject: Re: [osg-users] Paging dual-core


Hi Zach,


On 3/14/07, Zach Deedler <[EMAIL PROTECTED]> wrote: 

Somehow the paging thread is running with disregard for the graphics thread.
I'm guessing this is when it is loading a large file, and there are no
checks in the code to relinquish control.  This is where the OS should step
in and say 'stop hogging the resources!', and switch to the other thread
(who has priority).  I don't know why this isn't happening.  I'm not sure
what 'resources' it is hogging though.  Should I just give up, and say the
OS sucks?  That's what everyone keeps telling me.  This is proof enough,
unless there is something wrong with OpenThreads setting of priorities.
Although, that doesn't seem to be the case looking at the graphs in the
previous email I sent.


The resource locking up does very much look an OS issue.  This means any
fixes are not really to problems inherit to the OSG's database paging but
workarounds to avoid pushing the OS too much. 

Perhaps it doesn't like changing of priorities the DatabasePager between
inside and outside the frame.  If you have processor assigned to the
database pager and one assigned to the graphics thread then you shouldn't
ever need to manage priorities - both threads should be able to run at top
priority and not impact each other.  The caveat to this is the other
processes running on the machine will need scheduling too, so I'm would set
the priority of the DatabasePager lower than then graphics thread anyway so
the OS will naturally plonk these processes on these cores. 

Another little thing to think about is the number of hyper-threading vs real
cores, so if you want to set affinity of two threads on the "four" core
Pentium D then assign the two threads to different physical cores rather
than the hyper-thread two processes on a single core. 

Robert.

 

_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to