I have a scene with only many boxes. When I use the SI solver, all works fine ( less than 1ms processing time ). However, if I use the mlcp solver (with Dantzig), the processing time go up to 130 ms or more.... Is this ok?, I know that the mlcp solver is more expensive than SI solver, but 130ms is too much I think D=
The profiling tell that "processIsland" is consuming all the processing time, is this ok?
Some tip or advice is welcome ( I need the mlcp solver because I need to work with large mass ratios ).
I assume you made the minimum batch size 1 as in the demo, so it might have to do with island processing gobbling up cycles somewhere. There is a section of code that could fall apart if it somehow processes 90 islands that fit a very narrow selection of criteria, but I've never seen that happen in my own testing. I suggest you add a few profiler entries (like BT_PROFILE("processIslands"); but with a different name) and try to narrow down exactly where the processing is heaviest
I assume you made the minimum batch size 1 as in the demo, so it might have to do with island processing gobbling up cycles somewhere. There is a section of code that could fall apart if it somehow processes 90 islands that fit a very narrow selection of criteria, but I've never seen that happen in my own testing. I suggest you add a few profiler entries (like BT_PROFILE("processIslands"); but with a different name) and try to narrow down exactly where the processing is heaviest
yes, I had the minimum batch size in 1. I will try to find the exactly point, thanks!!.
By the way, do you have an estimation how much process time would be a "normal increase" respect to the SI solver? (would be nice have a reference =P )
gdlk wrote:
By the way, do you have an estimation how much process time would be a "normal increase" respect to the SI solver? (would be nice have a reference =P )
Depends on at lot of things! In fact, some MLCP solvers are faster than SI for the same result (one simulation of mine is a bit funky until about 150-200 iterations per joint) for very small islands. A (incredibly) rough estimate would be number of iterations*sum of constraints (SI) vs sum of the square number of constraints per island (for MLCP), but it's really had to tell what your average and worst case performance will be. The above is pretty much what I have seen in my own trials, with a tiny simulation of 3 hinge joints being about 7x faster with Dantzig than 200 iteration SI (with occasional spikes down to just equal).
If you're looking at very large simulations, there's some papers on multithreaded Dantzig solvers which scale well up to about a dozen cores, though I can't say if they actually work well with bullet.
gdlk wrote:
By the way, do you have an estimation how much process time would be a "normal increase" respect to the SI solver? (would be nice have a reference =P )
Depends on at lot of things! In fact, some MLCP solvers are faster than SI for the same result (one simulation of mine is a bit funky until about 150-200 iterations per joint) for very small islands. A (incredibly) rough estimate would be number of iterations*sum of constraints (SI) vs sum of the square number of constraints per island (for MLCP), but it's really had to tell what your average and worst case performance will be. The above is pretty much what I have seen in my own trials, with a tiny simulation of 3 hinge joints being about 7x faster with Dantzig than 200 iteration SI (with occasional spikes down to just equal).
If you're looking at very large simulations, there's some papers on multithreaded Dantzig solvers which scale well up to about a dozen cores, though I can't say if they actually work well with bullet.
Thanks!!, with that I have a better idea what to expect in performance =D ( I was really blind in that sense ).