I tested that Kotlin/Native has poor performance on iOS. For example, the most commonly used Matrix class needs to call the floatArrayOf function to construct it, but this function takes ten times as long on iOS as on Android.
Will the performance problems of Kotlin/Native cause Compose to not always get a better experience on iOS?
Test Code
val time = measureTime {
repeat(10000) {
floatArray = floatArrayOf(
1f, 0f, 0f, 0f,
0f, 1f, 0f, 0f,
0f, 0f, 1f, 0f,
0f, 0f, 0f, 1f
)
}
}
println("timeTest = $time")