William wrote:OP - have you had chance to test these changes or to test with Android 8?
Thanks,
William
Hello William,
thank you for your patience. After I updated my IDE, it shot down Git and I didn't wanted to continue making fundamental changes before fixing that.
First things first, Android 8 Oreo has a marketshare of 0.3 % right now (even below Android 2). Devices with Android 8 are rather rare. Android 5 (2014) and 6 (2015) with 50 % marketshare is therefore used as a base reference by now and probably for the next months - I can't give an ETA for that.
I have compared 3.2.5 and 3.2.4 with one another and measured the same application in two different scenarios:
- release mode (this is where the VM optimizer kicks in)
- debug mode (profiler - not recording)
Long story short:
- Debug mode: 3.2.5 has a 10 % increased performance (270+- to 300+ ms)
- Release mode: 3.2.5 has a 25 % increased performance (30+- to 40+ ms and 15 to 20 ms)
- The AABB+Vector allocation count reduced from 27,000 allocations in 36 seconds (750 a/s) to 7,000 in 45 seconds (169 a/s) total.
It wasn't very easy to measure the performance reliably and it took a while to get consistent results with different configurations. I believe this is due to nature of the big.little CPU architecture that switches to a more powerful CPU when the load increases and vice versa. At the end I used a sleep time of 100 and 1 ms in between.
Please note that I forced dyn4j to update every cycle by calling world.update(1000);.
Here are some screenshots from the cpu and memory profiler (debug mode - recording).
If you look closely at the very top of this flame chart, you are going to notice that Vector (o.d.g.V) and AABB (o.d.g.A) "<init>" is gone.