Preferred Cross-Compiler? (Linux) - G Tablet Android Development

Why do some prefer code-sourcery (and oddly enough use much older versions of it) and some use gcc found in the android ndk.
I personally use v4.4.0 found in the ndk (versus v4.4.3) because 4.4.3 produces modules that won't load, giving an error I cannot remember.
I'm guessing there is an advantage to using xyz over abc.. optimizations comes to mind.. but I cannot really grasp how a given CCompiler would produce a better performing kernel over another.. maybe I'm right, maybe I'm wrong.. I'm definately uncertain (heh, irony) so I'd like to know what's up.

Related

I am done with Sense

Sense UI is slow on first-generation Android phones, and all the attempts to make it fast only result in a flaky, weird experience.
The framework and everything else is closed-source, what do you expect?
All we can do is extract the APKs and modify images and maybe tweak the AndroidManifest.xml or other xml files. Even if we can extract the bytecode (if that's what it's called for the DalvikVM), it still isn't as open as an AOSP build.
The only reason I flashed Rosie/Sense UI ROMs were to get a nice homescreen (which was slow) with nice widgets and a browser with Flash (that was slow and incompatible but still useful for simple stuff).
I would have fun with the ROM for a while, but when I needed to be productive, like Google something quickly or add a note in AK Notepad, it was painfully slow.
Android 2.2 Froyo is amazing. It has many features, the most important IMO being a reliable JIT compiler for the DalvikVM, and Flash 10.1 coming to the browser OFFICIALLY!
When the source for Android 2.2 is released and Cyanogen makes a release for the G1/Dream, I'm stuck on that until I get a super Android phone with a full QWERTY like the G1
Sense is also UGLY.
As for this flash thing... its not going to work on your phone. Compiled for a different CPU.
Nothing lost there though, flash is terrible trash that the world would be MUCH better off withOUT.
lbcoder said:
Sense is also UGLY.
As for this flash thing... its not going to work on your phone. Compiled for a different CPU.
Nothing lost there though, flash is terrible trash that the world would be MUCH better off withOUT.
Click to expand...
Click to collapse
Did Flash murder you in a previous life?
It seems 50% of your posts here are about how Flash is the end of civilization?
Flash is a dreadful battery/CPU hog, and I suspect the 'net, as Apple claim, would be better off without it.
That said, given the propensity of web designers to use nonstandard, bloated, un-necessary flash widgets that break navigation everywhere in their pages, making them utterly useless to those with old machines, accessibility needs/disabilities, etc I guess it's probably better to have it than not. Flash 10.1 under FroYo is only marginally quirky on my Desire. Getting there!
Sense, OTOH, I miss... LauncherPro just isn't as pretty. But I think on older hardware like the G1, I'd agree with the OP. It's not necessary to get the most out of Android and if it's causing slowdowns, it's a bit counter-intuitive to the actual purpose of a mobile phone.
Azurael said:
That said, given the propensity of web designers to use nonstandard, bloated, un-necessary flash widgets that break navigation everywhere in their pages, making them utterly useless to those with old machines, accessibility needs/disabilities, etc I guess it's probably better to have it than not. Flash 10.1 under FroYo is only marginally quirky on my Desire. Getting there!
Click to expand...
Click to collapse
How about just not visiting those websites? Most even halfway marginal websites will provide "if (no flash) then show these links instead", of the rest, you can certainly get the information somewhere else, or failing that, you probably don't want it anyway (the developer is obviously retarded...)
The big important thing to note is that the web is changing. There is MUCH MUCH MUCH less flash around than there was 10 years ago. In fact, I can't think of a single site that actually still *requires* it (except maybe a few sites hosting videos of retards doing stupid crap). I can think of a few that have flash ads -- in these cases, NOT having flash dramatically improves your experience.
Different architectures
I remember a while back that there was a bug in Sense on the Hero where the package name (com.google.maps) would be displayed instead of the actual application name (Maps).
HTC acknowledged the problem and fixed it, but that's the problem with Sense; if it were open-source, someone (probably on xda) would release a tiny patch to fix the problem. Like if Google made the same mistake in the default Launcher, it would be fixed by the devs online quickly.
And now about Flash: What!? Wasn't it built for ARM? Or do the N1 and other superphones use a slightly different architecture? This is weird...
Another problem is that there are netbooks and all sorts of smartphones with Android.
Most netbooks will have x86 processors (Intel, AMD) and though most smartphones are expected to use ARM, some might use a different architecture like MIPS, or even x86 in the future.
Normal Android applications that are made with Java are fine, but how about all the apps with native binaries built with the Android NDK?
What Google should do is implement a way to compile the same program to all popular architectures, and keep the different binaries in the APK.
Apple did something similar in Mac OS X when they switched from PowerPC to Intel... application files in Mac OS X are basically a package that holds basic information, icons, and the binaries, which make this file format similar to Android APKs, except that when someone compiles their program for OS X, both PowerPC and Intel binaries are compiled and stored in the application.
If Google does this for Android, there will be no problem with different architectures (like with Flash not being able to run on the G1)
PSP_Hacker said:
I remember a while back that there was a bug in Sense on the Hero where the package name (com.google.maps) would be displayed instead of the actual application name (Maps).
HTC acknowledged the problem and fixed it, but that's the problem with Sense; if it were open-source, someone (probably on xda) would release a tiny patch to fix the problem. Like if Google made the same mistake in the default Launcher, it would be fixed by the devs online quickly.
And now about Flash: What!? Wasn't it built for ARM? Or do the N1 and other superphones use a slightly different architecture? This is weird...
Click to expand...
Click to collapse
Just like i686 binaries won't run on an i486 CPU, ARM7 binaries won't run on an ARM5 CPU. There are architectural changes that break compatibility of new binaries on old hardware.
Another problem is that there are netbooks and all sorts of smartphones with Android.
Most netbooks will have x86 processors (Intel, AMD) and though most smartphones are expected to use ARM, some might use a different architecture like MIPS, or even x86 in the future.
Normal Android applications that are made with Java are fine, but how about all the apps with native binaries built with the Android NDK?
Click to expand...
Click to collapse
Not all native applications are built with the NDK. Flash is a big example -- it has a lot of HAND WRITTEN ASSEMBLY CODE. There is NO automatic way to generate hand written assembly code. Each additional platform you support MUST have its own manually written code.
What Google should do is implement a way to compile the same program to all popular architectures, and keep the different binaries in the APK.
Click to expand...
Click to collapse
http://developer.android.com/sdk/ndk/index.html
Might not be a bad idea to read up on the ndk.
The applicable line is "You can also build for both architectures at the same time and have everything stored in the final .apk". Seems that they already thought of this
*** but it isn't applicable to flash since flash is partially hand-written. They could easily include the various binaries within a single APK file, but that won't happen unless they actually build the arm5 binary, which is extremely unlikely.
If Google does this for Android, there will be no problem with different architectures (like with Flash not being able to run on the G1)
Click to expand...
Click to collapse
For reasons mentioned above, this doesn't help.

An audience with… Nobody at all...!!!

exactly his words...
""So yes, I’m interested in ICS but not until it’s fluid enough. I won’t publish a MiniCM9 unless hw acceleration works to an extent that the UI feels good to use and functionality is acceptable. I would also like to see kernel flashing via CWM (the way it should be actually), which is a distant dream for the time being. Rebasing on another kernel version is also intriguing but requires a huge effort.""

[Q] Root N7 or not, for what I use it for?

Hi all,
First post as just registered here but XDA seems to be the best place for this subject by far.
Should I root and unlock, install kernel, overclock etc?
I use it for:
-Emails (Business & personal)
-Web browsing (a lot)
-Some games (but simple ones)
-Viewing and editing (slightly) Images.
-Google Analytics/Ads/Drive
-CRM database etc
In addition to the above question, I want to now if overclocking to 1.4, 1.5 or 1.6 ghz or install would make the N7 smoother and faster for these general things? I wont be 'gaming' or doing anything massively graphics or processor intensive (I dont think?)
iAmlearning said:
Hi all,
First post as just registered here but XDA seems to be the best place for this subject by far.
Should I root and unlock, install kernel, overclock etc?
I use it for:
-Emails (Business & personal)
-Web browsing (a lot)
-Some games (but simple ones)
-Viewing and editing (slightly) Images.
-Google Analytics/Ads/Drive
-CRM database etc
In addition to the above question, I want to now if overclocking to 1.4, 1.5 or 1.6 ghz or install would make the N7 smoother and faster for these general things? I wont be 'gaming' or doing anything massively graphics or processor intensive (I dont think?)
Click to expand...
Click to collapse
Based on your uses I'd leave it stock...you could however install a custom kernel and squeeze some more battery life out of it.
Risk and Difficulty?
Culex316 said:
Based on your uses I'd leave it stock...you could however install a custom kernel and squeeze some more battery life out of it.
Click to expand...
Click to collapse
Ok thanks, I have thought about battery life however I am willing to sacrifice a little battery for more speed. Do you think you'd notice the difference? In terms of smoothness and speed on general activities? Also one BIG question(s), how hard it is and how risky is it to root from Mac? Whats the likelihood of me ruining my device, for good? Are we saying 1 in 1000 or for a rookie like me a toss of a coin?
I have watched a few videos and find it pretty amazing what you can do to a phone or tablet. Especially by yourself.
iAmlearning said:
Hi all,
First post as just registered here but XDA seems to be the best place for this subject by far.
Should I root and unlock, install kernel, overclock etc?
I use it for:
-Emails (Business & personal)
-Web browsing (a lot)
-Some games (but simple ones)
-Viewing and editing (slightly) Images.
-Google Analytics/Ads/Drive
-CRM database etc
In addition to the above question, I want to now if overclocking to 1.4, 1.5 or 1.6 ghz or install would make the N7 smoother and faster for these general things? I wont be 'gaming' or doing anything massively graphics or processor intensive (I dont think?)
Click to expand...
Click to collapse
Hi, iAmlearning...
Based on your needs... I would say... stay stock, but root...
You can then run apps like Titanium (always useful for backing up those Temple Run 2 high scores.. or running AdAway (for getting rid of those pesky, annoying ads that seem to crop up just about everywhere...)
As far as risk is concerned... well, it's not really quantifiable... there is ALWAYS the possibility you might hard-brick the thing... but then, you might drop it on the kitchen floor tomorrow!
I'd be a liar if I said the Nexus 7 was 'unbrickable' ... it is eminently 'brickable'! But it's actually kind of hard to do! And if you follow many of the excellent instructions here on XDA, you should be OK. (Actually, rooting is a piece of cake - people make too much of it.)
Finally... rooting involves unlocking the BOOTLOADER... which WIPES the device and performs a FACTORY RESET... so I would suggest it might be done sooner rather than later... before you build up a lot of content on it (not that it can't be backed up elsewhere beforehand).
Once you have root, you can then think about custom ROMs and kernels much later.
But root is you're gateway.
Rgrds,
Ged.
iAmlearning said:
Hi all,
First post as just registered here but XDA seems to be the best place for this subject by far.
Should I root and unlock, install kernel, overclock etc?
I use it for:
-Emails (Business & personal)
-Web browsing (a lot)
-Some games (but simple ones)
-Viewing and editing (slightly) Images.
-Google Analytics/Ads/Drive
-CRM database etc
In addition to the above question, I want to now if overclocking to 1.4, 1.5 or 1.6 ghz or install would make the N7 smoother and faster for these general things? I wont be 'gaming' or doing anything massively graphics or processor intensive (I dont think?)
Click to expand...
Click to collapse
Doesn't sound like you really need to root. If you get sick of the interface or whatever you can always install a launcher like Nova Prime and play around with it. The things you can do without being rooted is pretty amazing.
Overclocking it to 1.4 Ghz won't make a huge difference, but overclocking to 1.8 Ghz will. It will also drain your battery a lot faster - something to think about. I'm one of the under clockers to preserve battery.
One further question?
ynrozturk said:
Doesn't sound like you really need to root. If you get sick of the interface or whatever you can always install a launcher like Nova Prime and play around with it. The things you can do without being rooted is pretty amazing.
Overclocking it to 1.4 Ghz won't make a huge difference, but overclocking to 1.8 Ghz will. It will also drain your battery a lot faster - something to think about. I'm one of the under clockers to preserve battery.
Click to expand...
Click to collapse
You have probably answered my question, I am a bit scared to overclock past 1.4 or 1.5 due to the heat and me not really knowing what I am doing and as the battery life is fairly important I might just leave as stock.
However like a few people advise I may try to give the rooting a go.... or maybe find a cheap used tablet or handset and try it on that first?
Would be great to get rid of the adverts.
Question - I have heard that some of these customer ROM's take away the unnecessary junk from the OS and make things smoother and faster? Would this be more worthwhile than overclocking if I were to do just one? Also any ROM's for this purpose that people recommend?
Thans again everyone
Well because the device is a Nexus device, it comes very clean as default. Not really any junk on the device to slow it down, even though that "junk" is relative. For example, I live in Europe and Google Play Music does not work over here, so I've disabled it. I've also disabled Google Currents, and any other built in apps that I simply do not use. Now it's like those apps are not even on my device - they are just dead.
If we were talking about a Samsung tablet, then yes I would say root it. Because rooting would allow you to get rid of Samsung's Touchwiz interface, which can be a bit of a RAM hog. But the Nexus 7 doesn't have such a problem, it's already stock and very smooth.
I can tell that you're very interested in this stuff and you will most probably root in the near future. However, my advice to you would be to just use and enjoy the device as it is right now, but in the mean time just read about how to unlock bootloaders, rooting, custom ROM's.. read as much as you can. You'll get more familiar with the process and the terminology, and it will be a big help when it comes time to root two months down the line.
One custom ROM I can recommend is Paranoid Android. Truthfully, it's the only one I can recommend because its the only one I've flashed. I like it, but does it make a huge difference from stock in terms of speed? Not really. It has a load of other cool features, though.
If all you're interested in is battery life and performance, rooting and a custom kernel would suffice. However for what you say you'll be using it for, not really needed. The nexus line is super simple to root and play around on though. It all sounds way more complicated than it really is.
Sent from my Paranoid 3.0 Nexus7 running M-Kernel mr1
ynrozturk said:
Well because the device is a Nexus device, it comes very clean as default. Not really any junk on the device to slow it down, even though that "junk" is relative. For example, I live in Europe and Google Play Music does not work over here, so I've disabled it. I've also disabled Google Currents, and any other built in apps that I simply do not use. Now it's like those apps are not even on my device - they are just dead.
If we were talking about a Samsung tablet, then yes I would say root it. Because rooting would allow you to get rid of Samsung's Touchwiz interface, which can be a bit of a RAM hog. But the Nexus 7 doesn't have such a problem, it's already stock and very smooth.
I can tell that you're very interested in this stuff and you will most probably root in the near future. However, my advice to you would be to just use and enjoy the device as it is right now, but in the mean time just read about how to unlock bootloaders, rooting, custom ROM's.. read as much as you can. You'll get more familiar with the process and the terminology, and it will be a big help when it comes time to root two months down the line.
One custom ROM I can recommend is Paranoid Android. Truthfully, it's the only one I can recommend because its the only one I've flashed. I like it, but does it make a huge difference from stock in terms of speed? Not really. It has a load of other cool features, though.
Click to expand...
Click to collapse
Quite impressed that you can determine this, as its 100% correct. I am probably going to do this at some point, but maybe not just yet, I think I need to get comfortable with the process and research a bit more about it all. Also, I am actually very impressed with the Nexus 7 as it id and coming from an Apple iPhone 5 and iPad 3, I can safely say that I'd not go back to either after this. I used to think Apple had it all in terms of functionality and innovation, however in recent years they have almost made backwards steps.
But thanks for the response, I keep seeing the Paranoid ROM around and on signatures. So may give that a go.
iAmlearning said:
Quite impressed that you can determine this, as its 100% correct. I am probably going to do this at some point, but maybe not just yet, I think I need to get comfortable with the process and research a bit more about it all. Also, I am actually very impressed with the Nexus 7 as it id and coming from an Apple iPhone 5 and iPad 3, I can safely say that I'd not go back to either after this. I used to think Apple had it all in terms of functionality and innovation, however in recent years they have almost made backwards steps.
But thanks for the response, I keep seeing the Paranoid ROM around and on signatures. So may give that a go.
Click to expand...
Click to collapse
I wouldnt root it for the uses you are indicating, BUT from your post I can already see that you eventually will. My advise is set a saturday or friday night aside and get this done sooner than later. Its just easier because this device not having an SD card will make it difficult to restore data and things that you have already done on it ( I got it two days ago and still havent rooted but am already worreid about some of the work ). The thing that usually helps me the most is youtube. Read a lot but have a good comprehensive detailed youtube video of teh rooting method you decide to follow and just follow along with the video. I have rooted 3 phones using that method and have yet to brick anything.

[Discussion]Will/How ART make an impact on developers

Ichigo said:
So, as you all know Android kitkat 4.4 came out recently. Along with it was ART, a replacement for Dalvik that promises faster and more efficient execution, better battery life, and a more fluid experience. ART stands for Android Runtime, and executes apps different than Dalvik. ART uses AOT to execute apps, which is pre-compiling bytecode into machine language when apps are first installed, turning them into truly native apps. ART still is still experimental currently, but let's discuss our opinions.
I know that when programming games for android, if it uses heavy 3D translations, you'll to use the NDK, coding in C or C++, allowing the app to run natively, and helps maintain frame rate and speed. Because the ART has apps running natively now, will it possibly help maintain framerate and speed better on lower-end devices? I know java is much slower slower than c++, but will running the java coded app natively help at all?
Anyways, share your opinions, ideas, or questions.
Click to expand...
Click to collapse
I don't know much about ART, but from what I heard this sounds awesome . I think that it is just crazy not to precompile the code into machine language, sure there is longer install times, but hey, the apps should run much faster.
The thing is that currently it is quite hard to try it out, even on KitKat (which I don't have yet). Would love to make a comparison between the two
Here are some benchmarks by Android Police: http://www.androidpolice.com/2013/1...ormance-wont-blow-away-today-will-get-better/
I hope that they will improve that method. If they do, it will be amazing.
Apps could much faster.
I do, however, like Java. One of the reasons why I prefer Android to Ubuntu Touch (which uses C++).
nikwen said:
Here are some benchmarks by Android Police: http://www.androidpolice.com/2013/1...ormance-wont-blow-away-today-will-get-better/
I hope that they will improve that method. If they do, it will be amazing.
Apps could much faster.
I do, however, like Java. One of the reasons why I prefer Android to Ubuntu Touch (which uses C++).
Click to expand...
Click to collapse
When KitKat comes to Nexus 4 I'll do some before/after benchmarking on MagicKeyboard (since it is fairly predictable and CPU intensive) - sounds quite promising.
PicomatStudios said:
When KitKat comes to Nexus 4 I'll do some before/after benchmarking on MagicKeyboard (since it is fairly predictable and CPU intensive) - sounds quite promising.
Click to expand...
Click to collapse
Kitkat is here on our Nexus 4s.
nikwen said:
Kitkat is here on our Nexus 4s.
Click to expand...
Click to collapse
Aw, yeah... I try to make a rule that wherever possible I use 'standard' build on our test devices, that way I can be sure I'm seeing what our users see
Depending how long it takes I might have a look !
PicomatStudios said:
Aw, yeah... I try to make a rule that wherever possible I use 'standard' build on our test devices, that way I can be sure I'm seeing what our users see
Depending how long it takes I might have a look !
Click to expand...
Click to collapse
Now the official ones are finally here.
nikwen said:
Now the official ones are finally here.
Click to expand...
Click to collapse
OK got it finally.
In a not particularly scientific test I tried typing the sentence
'The quick brown fox jumped over the lazy dog.'
into Magic Keyboard 2 (as many other apps as possible stopped, internet off, etc)
After each key press the app runs quite a large number of comparisons/calculations/bitshifts in a loop, in order to score the most likely word (CPU intensive work)
I only ran the test 3 times but there does seem to be an improvement with ART
Average prediction time for each configuration is:
Android 4.3:
20ms
Android 4.4 / Davlik:
19ms
Android 4.4 / ART:
15ms
From previous tests I know that the prediction times are fairly consistent.
Obviously the above is some way short of proof but early signs are good.
i am on android 4.4.4 with art runtime i haven't noticed any performance enactment and also not a single app cashing
Sent from my XT1022 using XDA Free mobile app

CAF/Non-CAF

I somewhat read what the difference between the two were, but I don't quite understand it completely. I was wondering (based on user preference) which is better.
I was using a ROM that was Non-CAF and now I'm using one that is, and I don't notice a difference really. I was wondering if someone could help me understand better.
+1
TheKnux said:
I somewhat read what the difference between the two were, but I don't quite understand it completely. I was wondering (based on user preference) which is better.
I was using a ROM that was Non-CAF and now I'm using one that is, and I don't notice a difference really. I was wondering if someone could help me understand better.
Click to expand...
Click to collapse
Caf relates to code aurora forum (Google it).. Its where Qualcomm updates its stuff regularly. While aosp is googles kernel branch. Caf has more updates and optimisations for Qualcomm chipsets. The difference... I can't say there is much since our phones are already quite powerful to handle most things thrown at it.. But again, as I mentioned its optimisations and etc, so on paper better performance, battery and what not.
Sent from my Nexus 4 using Tapatalk
CodeAurora (CAF) - These are Qualcomm's reference sources for their platform. This is what they provide to OEMs, and what nearly all OEMs base their software off of. As a result - nearly all non-Nexus devices are running kernels/display HALs/etc. that are derived from a CAF baseline.
Google's software baseline, or AOSP - Usually when Google starts working on a new Android version, they'll fork from CAF at the beginning. Very often Google will be adding "new" features specific to the new Android version, while Qualcomm will continue with performance enhancements and bugfixes against the "old" baseline.
So when a new Android revision comes out, you have two baselines: CAF which is usually "ahead" in performance but "behind" in features, and AOSP which is the opposite.
from what i've noticed CAF is better, i get less stuttering this is the sort of thing that optimizations usually improves on.

Categories

Resources