5 ms·
Yeah, I'm curious about that. When article said, "He lists benefits of Scala development for Android as speed, easier programming, . . . ." (emphasis mine), th
by Dove 15y ago
Yeah, I'm curious about that. When article said, "He lists benefits of Scala development for Android as speed, easier programming, . . . ." (emphasis mine), that turned my head a bit.
I would think the best Scala could hope for would be to match Java's performance. I can't imagine how it would be faster.
Are there actual numbers for Android development? What do you lose doing Scala and where?
- fosk 15y agoFound this, but not sure if it can be considered reliable: http://scala-programming-language.1934581.n4.nabble.com/Scala-on-Android-Performance-td2004054.html http://scala-programming-language.1934581.n4.nabble.com/Scal... The following one instead is an official Google doc with some benchmarks between Java/Scala/C++/Go (not specifically related to Android), where it's stated that actually Java would be more performant than Scala without the GC: https://days2011.scala-lang.org/sites/days2011/files/ws3-1-Hundt.pdf https://days2011.scala-lang.org/sites/days2011/files/ws3-1-H... "In other words, Scala spends 7699-2416-1 = 5282 clicks on non-GC code. Java spends 14073-10484-110-2 = 3477 clicks on non-GC code. Since GC has other negative performance side-effects, one could estimate that without the GC anomaly, Java would be about roughly 30% faster than Scala." Very interesting. Also, Scala JARs are 3.6x bigger than the Java equivalent (due to the runtime files, see page 7).