The Dart team received a lot of great feedback from the community in response to our various Dart presentations at Google I/O. We asked Lars Bak and Kasper Lund, Dart project co-founders, to help answer your questions. Here's what they shared. Enjoy!
Q01: Are there any plans for to use Dart as an alternative or replacement to Java for Android app development (native APK apps)? James Wendel, United States
A01: The current focus for Dart is web applications. Your best bet is to talk to the Android team about this.
Q02: In some benchmarks the DartVM is now outperforming the JVM. Do you you think it will be possible for the DartVM to outperform the JVM for most code? Are there specific areas where the JVM's design will allow it to perform better than the DartVM? Greg, Wellingtron
A02: For programs like numeric computations Java will always have a performance advantage over the Dart VM. The reason is that Dart code is dynamically typed whereas Java has built-in basic types like byte, int, and double. However, for object oriented application code we see no reason for not matching or exceeding the speed of JVMs. We will continue to push performance of the Dart VM since performance is a key driver for web application innovation.
Q03: Few years back GWT was heavily promoted by Google. Now Google is promoting Dart for the future web development. How could I convince my company towards those technology for the longer run? and what are benefits would I get if I choose? Thamizharasu, Chennai
A03: Dart is on track to get into Google Chrome, is used by critical internal projects, and has a growing community. Dart has commitment from Chrome, has a large and experienced team working on it, and the team is investigating how to place Dart into a standards organization.
A05: The Dart team's goal is be at least 2X faster than V8. See dartlang.org/performance for some benchmarks and results.
A06: We expect to take another look at what language features might help with async programming, but not until after 1.0 launch.
Q07: Any hints about possible future language features that could be added after 1.0 is released? Greg, Wellingtron
A07: We expect to implement enums. We also expect to explore features for async.
Q08: Today Google introduced new Android Studio. Is there a plan for releasing something similar for Dart? Valeriy, Ukraine
A08: We're happy that JetBrains has a Dart plugin for IntelliJ and WebStorm. The Dart team supports this effort, and collaborates with JetBrains. Also, you can try our Dart Editor.
Q09: Can you outline the distinctions between Dart and GO on the server side? Will Dart in the future compete with GO on the server side? thien bui, Berlin
Q10: Are there plans to extend SIMD support by adding new features like AVX and add GPU programming support to language and VM? mdakin, Zurich
A10: There are plans to take advantage of the new AVX instruction set. One example, would be adding Float32x8 type which fits inside the new 256-bit wide registers. Another example would be to use the new gather and permute instructions. There are no plans to add GPU programming support to Dart at this time.
Q11: EcmaScript 6 is taking shape - offers classes, modules, block scoped vars (let/const), iterators and other good stuff. asm.js offers performance. Why use Dart - especially if the DartVM is not built into Chrome(OS)/Blink and Android. kc, UK
Q12: What are the advantages/disadvantages of a sourcecode VM, such as Dart, versus a bytecode VM, such as the JVM? Greg, Wellingtron
A12: Productivity comes to mind. With a source code VM, you don't need to first compile code before running the app. Thus, the iteration cycles are much faster. Just edit and reload! This is important for web developers who want to iterate quickly. Note that the Dart VM internally generates machine code from the source code, via its optimizing compiler.
Also, a real disadvantage of a bytecode VM is the VM needs to verify the integrity of the bytecodes before they can be executed. This adds complexity and opens up for security problems.
Q14: If I develop a WebGL game, will I ever be able to target iOS and leverage the performance of the Dart VM or native compilation? Filipe Morgado, Portugal
A14: It is currently an outstanding research project to determine how to port Dart apps to iOS and still remain performant. Luckily, Dart is open source so we look forward to the community exploring this area.
Q15: Are there plans to introduce shared state concurrency and parallelism? Filipe Morgado, Portugal
A15: No, we’re not planning on supporting general shared state concurrency. Having said that, we are very interested in improving our support for concurrent and parallel algorithms.
Q16: Will SIMD support make it into V8? b, sf
A16: V8 implements the ECMAscript standard, so the question is really “will SIMD support make it into ECMAscript” and that is best answered by the ECMAscript committee.
Q17: Will there be an option to see the generated code along with actual Dart code in the editor in future? mdakin, Zurich
A17: That is a very good idea and certainly worth filing a feature request issue on http://dartbug.com/ for. In the meantime, you can output the generated code that the VM produces with this command:
dart --disassemble_optimized --code_comments
You can also try http://web.irhydra.googlecode.com/git/hydra.html to view the output from the Dart VM compiler.
Q18: Can you explain Dart to a six-year old? Ruudjah, Netherlands
A18: It is hard to explain any programming language to a six-year old, but maybe you could tell him/her that Dart is a tool that might make the next web version of Angry Birds have more pigs and angrier birds?