amorenew
07/03/2017, 3:03 AMbenleggiero
07/03/2017, 5:43 AMkarelpeeters
07/03/2017, 6:20 AMbenleggiero
07/03/2017, 6:23 AMkarelpeeters
07/03/2017, 6:30 AMdmitry.petrov
07/03/2017, 8:38 AMfor
are handled as compiler intrinsics.until
to ..
in for loops. In almost every single case it will have the same effect (unless your upper bound can be Int.MAX_VALUE
, but usually you don't care).
That way the generated code would be almost the same as if you had a Java loop such as for (int i = a; i < b; ++i) { ... }
, and it looks like HotSpot and both Android RTs optimize such loops better.