Running D in the Java VM

Paulo Pinto pjmlp at progtools.org
Thu Nov 21 11:27:34 PST 2013


Am 21.11.2013 16:34, schrieb John J:
> On 11/21/2013 02:35 AM, Volcz wrote:
>> On Sunday, 17 November 2013 at 05:49:43 UTC, John J wrote:
>>> On 11/15/2013 02:13 AM, Jeremy DeHaan wrote:
>>> If it should survive as an alternative, Jave should have some more
>>> advantages over D, even after the D compiles to ARM.
>>
>> The Android NDK is only a second class citizen compared to the Java SDK.
>> The only use case I have heard of for the NDK is when companies have a
>> small C library with common functionality to make porting the products
>> to other platforms easier.
>
> I thought NDK would be faster. If that's not the case, then I am mistaken.
> I also shouldn't discourage the OP. It's a fun project nevertheless.

So far the Android team has been very vocal against use of C and C++ in 
Android, given the Sun background of many top level developers, most likely.

It is seen as a necessary evil for game development and porting of 
legacy code.

You only have access to the indispensable set of APIs for game 
development, for everything else you need to use JNI for the Java APIs.

Native code is actually loaded as a shared object into a DalvikVM 
process. An App entry point is always Java code.

Even the new gaming APIs, the Android version of XBox Live, only have a 
Java based implementation.

In KitKat they introduced a new compiler for Java, which performs AOT 
compilation to native code via LLVM, called ART. It is still considered 
experimental and is planned to replace DalvikVM in a future release.

So far, from the three major mobile OS, Android is the one more hostile 
to native code, this might change of course.

This is very easy to verify, you just need to check the NDK mailing list 
or the respective documentation.

--
Paulo




More information about the Digitalmars-d-announce mailing list