Jump to content

LG screwed up - bad - here's why your UI is jerky!


Guest PaulOBrien

Recommended Posts

You might not have seen my main post on my Performance Audit, so I thought i'd post a seperate topic.

Basically i've been auditing the LG ROMs for performance tweaks today, and I came across a monstrous screw up by LG!

On device startup there is a piece of code which looks to check if the device is running an engineering build (this is set in the build.prop). If it is, then it sets up the system as such that dexopt doesn't happen at startup (which is normal), but happens on the fly. This is fine for engineering builds, but for user builds, it's a huge and unpredictable system overhead.

Now, in my audit I discovered that LG have manually changed this code to always return 'true' instead of looking at the build.prop! So the device always runs it's dexopt in engineering mode (no pre-dexopt). Crazy! This explains the slowdowns and random weirdness we have been seeing. I've reversed 3 LG builds and they all have this problem.

I've now fixed it and i've implemented the fix in my Fr7 releases but, well, bad LG! :D

P

PS For the techies amongst you, let me post the code snippets below.

The 'stock' Google code (smali):

	const-string v5, "eng"

const-string v6, "ro.build.type"

invoke-static {v6}, Landroid/os/SystemProperties;->get(Ljava/lang/String;)Ljava/lang/String;

move-result-object v6

invoke-virtual {v5, v6}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v5[/code] LG's code (smali):
[code] const/4 v5, 0x1

LMAO! B)

Link to comment
Share on other sites

Guest sibbor

I hope LG sees this and fixes it in an upcoming official build. They should be embarrassed ;-)

Perhaps they should create a pre-release TODO list and include this issue on it.

Edit: I'm back here to thank you once again, P. This fix made the phone smooth as butter. Geez, what a different! Thanks for you quick prebakes... running Fr7 since a few hours, without any issues.

Edited by sibbor
Link to comment
Share on other sites

Cool Paul. Will install Fr7 now and check it out. Would you be able to also merge to overclocking options from Cpasjuste (XDA) into your kernal? Or release your sources to him so he can make the changes himself? That would be great :D

Link to comment
Share on other sites

Guest Korumera

I can code a bit but everybody can see that the stock code is better then the LG version tho :D

I indeed hope they will fix this before the release GB to the general population B).

Link to comment
Share on other sites

Cool Paul. Will install Fr7 now and check it out. Would you be able to also merge to overclocking options from Cpasjuste (XDA) into your kernal? Or release your sources to him so he can make the changes himself? That would be great :D

Yes, i'll be posting my kernel sources to my github.

P

Link to comment
Share on other sites

Guest Frank Sem-Jacobsen

So what is the effect of this in layman's terms? Will it only affect the first run of an application, or every time an application is launched, leading to general instabilities?

Link to comment
Share on other sites

I saw it doing it for apps multiple times, at weird times... which is kinda odd. I was doing something in one app, and i'd see it generate dex for Dolphin Browser in the background for example. Very weird.

P

Link to comment
Share on other sites

Guest djmcnz
So what is the effect of this in layman's terms? Will it only affect the first run of an application, or every time an application is launched, leading to general instabilities?

I think it's explained pretty well in layman's terms in the first post...

Instead of taking a hit at boot, LG had set it to carry an overhead during normal use. Kind of the wrong way around.

Link to comment
Share on other sites

Guest SilentInfidel

Is there any possibility that this change was done deliberately as a work-around for some kind of bug that couldn't be fixed in time for release, such as a race condition? This is the first dual-core Android device after all. Of course I don't have any evidence of this, and I'm just trying to think of why LG might have done it.

Link to comment
Share on other sites

Guest djmcnz
Is there any possibility that this change was done deliberately as a work-around for some kind of bug that couldn't be fixed in time for release, such as a race condition? This is the first dual-core Android device after all. Of course I don't have any evidence of this, and I'm just trying to think of why LG might have done it.

We'll find out in a few hours/days!

But for sure the hw was clearly ready before the sw, the price you pay for trying to be #1 I suppose. And to be fair, at least they didn't have time to encrypt the bootloader lol!

I just think the CEO got one and said - "this takes too long to boot, fix it" - and they did... :D

Edited by djmcnz
Link to comment
Share on other sites

Is there any possibility that this change was done deliberately as a work-around for some kind of bug that couldn't be fixed in time for release, such as a race condition? This is the first dual-core Android device after all. Of course I don't have any evidence of this, and I'm just trying to think of why LG might have done it.

No. And it's not the first DC device. The Vega has very similar architecture and doesn't do this.

P

Link to comment
Share on other sites

Guest d-droid

Wow, truly amazing they would miss such a thing. Have you contacted them in any way? I suppose a tweet directing them here would do no good since marketing seldom are very techie but I'll try! :D

Link to comment
Share on other sites

Guest Stryke69

LOL. Nice job Paul (as always)! I really wonder why some people get paid for a job that others do much better in their freetime...

Edited by Stryke69
Link to comment
Share on other sites

Guest Bay Harbor Butcher

A friend of mine with italian LG dual,has a bad problem when phone is charging.

Sometimes,during the charge, he wants to use phone but it doesn't work and it appears to be off. He need to remove battery and then it boots.

Does FR7 fix this issue?Searching in the web he's not the one with this problem..

Thanks..

Edited by Bay Harbor Butcher
Link to comment
Share on other sites

Guest jivemaster
A friend of mine with italian LG dual,has a bad problem when phone is charging.

Sometimes,during the charge, he wants to use phone but it doesn't work and it appears to be off. He need to remove battery and then it boots.

Does FR7 fix this issue?Searching in the web he's not the one with this problem..

Thanks..

I would be greatly interested too if this fixes the random reboot issue. My wife's 2x reboots itself 1-2 times a day, and she sometimes pulls the phone out of her bag only to be welcomed by the black screen of death.

Link to comment
Share on other sites

Guest rex1701
A friend of mine with italian LG dual,has a bad problem when phone is charging.

Sometimes,during the charge, he wants to use phone but it doesn't work and it appears to be off. He need to remove battery and then it boots.

Does FR7 fix this issue?Searching in the web he's not the one with this problem..

Thanks..

No he isn't - only seen it once though - at least up until now...

/Rex

Link to comment
Share on other sites

Guest Batkoto
I would be greatly interested too if this fixes the random reboot issue. My wife's 2x reboots itself 1-2 times a day, and she sometimes pulls the phone out of her bag only to be welcomed by the black screen of death.

Which ROM version is your wife's 2X running. Stock or custom?

Link to comment
Share on other sites

Guest jivemaster
Which ROM version is your wife's 2X running. Stock or custom?

Just stock 2.2.2 rom from the factory. No root.

post-795988-1302130857_thumb.jpg

Edited by jivemaster
Link to comment
Share on other sites

Hi Paul:

I am on 10a, ro.build.date.utc 1299570033, HK/TW stock rom.

If I would like to look into the problem, which file and where abouts should I start looking at?

wonder would you mind share more info on the change?

Thanks a lot.

Edited by utp
Link to comment
Share on other sites

Guest Lucky-Strike

Hi !

First, thx Paul for your work.

Then, I have a question that might seems stupid/naïve, but I have to ask : have you any kind of contact with anybody at LG's ? 'Cause your work is really great, but they should clean their own mistakes by themselves, so that kind of issue needs to be noticed to them...

Moreover, some dev's email adress are in the code :D

Anyway, thx again.

Edited by Lucky-Strike
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.