What is the difference and performance hit of jvmTarget = 1.8 and kotlin-stdlib-jdk8 in kotlin

Viewed 147

We have multi module project and in most cases we can't use android ktx library extension functions (like viewModelScope) without changing jvmTarget to 1.8. I would like to create base library module with jvm target 1.8 which later we can apply for all modules. So its important to understand performance hit of changing jvmTarget to 1.8 from default (1.6) on android for module.

Already read question about jvm target, article about stdlibs, documentation

Could you please explain what is the difference between them? What happens if we change jvmTarget to 1.8 but continue using kotlin-stdlib-jdk7 ?

In documentation says that we need configure modules which uses only java8 features, but what is the performance hit if we configure java8 features for all modules?

Also in article about stdlibs says that from changing kotlin-library to kotlin-stdlib-jdk8 we won't benefit, but then why we need it?

0 Answers
Related