You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description.
I've noticed that VectorBuffer generally used in temporary vectors calculations inside RLib. It's good way but maybe it would be better a change general concept to the pool?
The pool may also work like buffer if control code won't put vectors back. In big calculations (planes, polygons, motions and other) if control code frequently calculate that stuff RLib will over-allocate necessary memory or waste in stupid way already stored vectors for temporary calculations.
We can optimize those cases with pooling. It will speed-up (vectors can run out in buffer and buffer must create new vectors, this case is memory allocation which we are trying to avoid; if vectors will be stored in buffer for too long, GC will move vectors to old-generation objects, it's a big problem in temporary calculation cases because vectors removal is going only in full GC stage) and save the memory (we can use vectors again and avoid memory over-allocations).
TL;DR
My suggestion: move all temporary calculations to pool and delete maybe VectorBuffer (I think VectorBuffer is not needed with pooling).
Risks.
Minimal risks inside RLib: it's a just like VectorBuffer refactor.
About exists projects where's RLib already using: need a analyze VectorBuffer usages, pluses and minuses by switch buffer to pool. I known you have some projects like jMonkeyBuilder where's RLib is used and you are need to analyze this issue to compability with your projects firstly.
Implementation.
I can do this issue if you agree.
The text was updated successfully, but these errors were encountered:
Description.
I've noticed that VectorBuffer generally used in temporary vectors calculations inside RLib. It's good way but maybe it would be better a change general concept to the pool?
The pool may also work like buffer if control code won't put vectors back. In big calculations (planes, polygons, motions and other) if control code frequently calculate that stuff RLib will over-allocate necessary memory or waste in stupid way already stored vectors for temporary calculations.
We can optimize those cases with pooling. It will speed-up (vectors can run out in buffer and buffer must create new vectors, this case is memory allocation which we are trying to avoid; if vectors will be stored in buffer for too long, GC will move vectors to old-generation objects, it's a big problem in temporary calculation cases because vectors removal is going only in full GC stage) and save the memory (we can use vectors again and avoid memory over-allocations).
TL;DR
My suggestion: move all temporary calculations to pool and delete maybe VectorBuffer (I think VectorBuffer is not needed with pooling).
Plan.
Or make interface:
VectorBuffer
usages toVector3Pool
.Risks.
Minimal risks inside RLib: it's a just like VectorBuffer refactor.
About exists projects where's RLib already using: need a analyze VectorBuffer usages, pluses and minuses by switch buffer to pool. I known you have some projects like jMonkeyBuilder where's RLib is used and you are need to analyze this issue to compability with your projects firstly.
Implementation.
I can do this issue if you agree.
The text was updated successfully, but these errors were encountered: