fix the mutex between garbage collection and physics engine.