this post was submitted on 02 Jul 2023
104 points (95.6% liked)

Android

27943 readers
116 users here now

DROID DOES

Welcome to the droidymcdroidface-iest, Lemmyest (Lemmiest), test, bestest, phoniest, pluckiest, snarkiest, and spiciest Android community on Lemmy (Do not respond)! Here you can participate in amazing discussions and events relating to all things Android.

The rules for posting and commenting, besides the rules defined here for lemmy.world, are as follows:

Rules


1. All posts must be relevant to Android devices/operating system.


2. Posts cannot be illegal or NSFW material.


3. No spam, self promotion, or upvote farming. Sources engaging in these behavior will be added to the Blacklist.


4. Non-whitelisted bots will be banned.


5. Engage respectfully: Harassment, flamebaiting, bad faith engagement, or agenda posting will result in your posts being removed. Excessive violations will result in temporary or permanent ban, depending on severity.


6. Memes are not allowed to be posts, but are allowed in the comments.


7. Posts from clickbait sources are heavily discouraged. Please de-clickbait titles if it needs to be submitted.


8. Submission statements of any length composed of your own thoughts inside the post text field are mandatory for any microblog posts, and are optional but recommended for article/image/video posts.


Community Resources:


We are Android girls*,

In our Lemmy.world.

The back is plastic,

It's fantastic.

*Well, not just girls: people of all gender identities are welcomed here.


Our Partner Communities:

!android@lemmy.ml


founded 1 year ago
MODERATORS
 

More concretely, I'm asking this: why aren't applications compiled fully to native code before distribution rather than bytecode that runs on some virtual machine or runtime environment?

Implementation details aside, fundamentally, an Android application consists of bytecode, static resources, etc. In the Java world, I understand that the main appeal of having the JVM is to allow for enhanced portability and maybe also improved security. I know Android uses ART, but it remains that the applications are composed of processor-independent bytecode that leads to all this complex design to convert it into runnable code in some efficient manner. See: ART optimizing profiles, JIT compilation, JIT/AOT Hybrid Compilation... that's a lot of work to support this complex design.

Android only officially supports arm64 currently, so why the extra complexity? Is this a vestigial remnant of the past? If so, with the move up in minimum supported versions, I should think Android should be transitioning to a binary distribution model at a natural point where compatibility is breaking. What benefit is being realized from all this runtime complexity?

you are viewing a single comment's thread
view the rest of the comments
[–] DrJenkem@lemmy.blugatch.tube 11 points 1 year ago (5 children)

X86 android devices exist, wether they are officially supported or not, I don't know. C/C++ is prone to memory corruption vulnerabilities, using a higher level language like Java nearly entirely cuts out that class of vulnerabilities. You mention the complexity of Java, but Java is just a lot easier to write than c/c++. So I ask you, why would android switch to the complexity of c/c++ for applications where Java is sufficient?

[–] aluminium@lemmy.world 8 points 1 year ago (2 children)

They must be, plenty of x86 Chromebooks get Playstore verified each year.

[–] DrJenkem@lemmy.blugatch.tube 1 points 1 year ago (1 children)

True, and while x86 phones exist, they're pretty rare. But I think x86 tablets are a bit more common.

[–] Never_Sm1le@lemmy.world 1 points 1 year ago

Yes, there's plenty of cheap Windows-Android dualboot tablets/laptops

load more comments (2 replies)