Hey guys, can you recommend any resource from wher...
# android
r
Hey guys, can you recommend any resource from where I can better understand meaning and significance of different keywords appearing in the generated Kotlin Bytecode such as ALOAD, ASTORE, LDC etc. Thanks. I'm trying to find an answer to a question that does having many classes (all classes are used or referenced somewhere) deteriorate the performance of an android app? The preliminary step I'm taking is to look at the bytecode as I'm assuming that more the number of instructions in the generated bytecode less performant will the app get. Thanks
not kotlin but kotlin colored 2
c
That bytecode is not Kotlin‘s but Java‘s https://en.wikipedia.org/wiki/List_of_Java_bytecode_instructions
r
Oh i should have searched in Java's reference got it. thanks!
e
also no your assumption is wrong
Java HotSpot JIT optimizes a whole function at a time, including recognizing sequences of multiple bytecode operations that can be performed in a different number of native operations. the number of bytecode instructions has little bearing on the performance
also they don't get mapped 1:1 to Dalvik bytecode which is what actually ends up on Android devices
then ART's optimizations are also not translating that 1:1 to native instructions either
if you want to measure performance, you have to actually measure performance
1
r
thanks for the info, but a significant difference in the number of bytecode instructions would definitely be reflected in the performance right?
e
depends on the instructions
r
ok