jerdog · May 6, 2012 at 07:00 am

C#: The Future of Android?

If you haven’t heard, Google and Oracle are locked in a dispute over the Android OS and its use of Java code. This struggle could have strong repercussions for the world’s most popular mobile OS.

With that realization Xamarin, makers of the open-source and cross-platform mobile .NET application development platform Mono, sat down almost a year ago to look at the Android platform and see what could be done to improve battery life and Android application performance. Eventually their team came to the conclusion that C# offered a more robust base than Java, with fewer coding limitations and faster performance. In their words:

Over and over we came back to the basics: Dalvik is a young virtual machine, it is not as performant or tuned as Mono and suffers from many of Java’s performance limitations without the benefit of the high-end optimizations from Oracle’s HotSpot. One crazy idea that the team had at that dinner was to translate Android’s source code to C#. Android would benefit from C# performance features like structures, P/Invoke, real generics and our more mature runtime.

Although nothing happened back in July, this idea stuck in the back of our minds.

Fast forward a few months: Mono for Android is doing great, and we are starting to think again about improving our own product’s performance on Android. What if we could swap out Java with faster C# and get rid of various Dalvik limitations in the process? Could we create an Android phone completely free of Java, and free of the limitations of the Dalvik VM?

We decided it was crazy enough to try. So we started a small skunkworks project with the goal of doing a machine translation of Android from Java to C#. We called this project XobotOS.

Xamarin then began the XobotOS project to port Android 4.0 to C# using their open-source tool Sharpen. While they no longer are focusing on XobotOS, they have open-sourced the project on GitHub. Could this be the answer to Google’s current legal battles? Given the depth of the necessary ecosystem changes, this seems unlikely. However, it presents an interesting possibility for those willing to tinker with the open-source code above.


_________
Want something on the XDA Portal? Send us a tip!
TAGS:

jerdog

jerdog is an editor on XDA-Developers, the largest community for Android users. Jeremy has been an XDA member since 2007, and has been involved in technology in one way or another, dating back to when he was 8 years old and was given his first PC in 1984 - which promptly got formatted. It was a match made in the stars, and he never looked back. He has owned, to date, over 60 mobile devices over the last 15 years and mobile technology just clicks with him. In addition to being a News Editor and OEM Relations Manager, he is a Senior Moderator and member of the Developer and Moderator Committees at XDA. View jerdog's posts and articles here.
Mathew Brack · May 22, 2015 at 02:30 pm · 4 comments

Introducing Voices of XDA: Have Your Ideas Heard

By far the greatest assets we have at XDA-Developers are you, the developers, the eager to learn and the bold. Everyday we see innovation and brilliant ideas across the site, from this we know that many of you have great insight in to your respective fields. That is why today, I am honored to announce a new project that will allow us to work with you directly to have your views and thoughts expressed clearer than ever. Introducing:    ...

XDA NEWS
Jimmy McGee · May 22, 2015 at 12:10 pm · 4 comments

YotaPhone 2 Pre-Order, Xperia Z1 Price Cut – XDA TV

Android Wear 5.1.1 OTA downloads are now available. That and much more news is covered by Jordan when he reviews all the important stories from this week. Included in this week's news is the announcement of Sony cutting the price of the Xperia Z1 and be sure to check out the article talking about the YotaPhone 2 Indiegogo pre-order. That's not all that's covered in today's video! Jordan talks about the other videos released this week on XDA TV. XDA...

XDA NEWS
TK · May 21, 2015 at 02:15 pm · 3 comments

Device Review: No.1 X1 Rugged Smartphone

We are almost at the end of Q2 for 2015, and we have seen most of the flagship phones for the year already. While flagship phones usually offer bleeding-edge specs and are the most sought after phones, there is a huge market for non-flagship phones. Some offer value, others offer unique differentiating features. Today, we are going to look at the X1 phone by a Chinese company named N0.1. The company promises a truly rugged IP68 Certified phone. The device has a Quad...

XDA NEWS
Share This