dmitry.petrov
04/26/2016, 8:00 AMfor
, when
, string templates / string concatenation) have specific code generation schemes (e.g., for
over a range, when
by constant selectors, etc) that produce "optimized" bytecode.
3. A few functions and properties are implemented as compiler intrinsics (yet again, a particular bytecode generation scheme provided by compiler).
Sometimes it can be treated as an "optimization". E.g., A::class.java
doesn't create an intermediate KClass object.
4. Bytecode postprocessing steps eliminate redundant boxing/unboxing, redundant null checks, and dead code. Such transformations are intraprocedural (that is, within a context of a single method), so, as mentioned above, inline functions provide additional benefits here.