Optimized Array Handling in JRE impl

I optimized some code in the JRE Arrays class. This made JBox2D run x-times faster.
Well, this seems to work, this implementation is adapted from the TeaVM JRE classes...