From: Yuan X. <xuy...@gm...> - 2008-03-07 08:29:45
|
Hi Hedayat and all, I take a look at current multi-thread implementation. But I can not understand it exactly, could you help me? 1). in simulationserver.cpp 00491 Step(); 00492 ControlEvent(CE_EndCycle); The Step() calls mSceneServer->Pre/PostPhysicsUpdate() again, I think it is redundant, what should be called maybe mSceneServer->PhysicsUpdate(mSimStep), right? Place ControlEvent(CE_EndCycle) here is for rendering function in the main thread? The original code can not work with Mesa-6.4.1, it can work with Mesa-6.5.21 and ATI fglrx 8.31.5 . I checked the ChanegeLog of Mesa, there are some bug-fixes of thread safe in Mesa-6.5. Can you test that? 2). Synchronization by the barrier just make all the threads run one by one, it is not the real parallel. The original idea is make SimControlNodes run parallel, and PhysicsUpdate can also run at the same time. Since the scene tree can be used as cache. PrePhysicsUpdate copy data from scene tree to ODE, PosPhysicsUpdate copy data from ODE to scene tree. PhysicsUpdate only effects ODE internal data. ( To Joschka, Sorry, I do not finished the document work about single-thread and multi-thread. I want to make things clear firstly.) -- Best wishes! Xu Yuan School of Automation Southeast University, Nanjing, China mail: xuy...@gm... xy...@ya... web: http://xuyuan.cn.googlepages.com -------------------------------------------------- |