Possible workaround for laggy UI response (stock firmware build 6.2.A.0.400) - Sony Xperia P, U, Sola, Go

This post is intended for only rooted users of Xperia go/P/U/sola phones that are currently running the stock firmware build 6.2.A.0.400 / Jelly Bean (or in the case of U/sola, the ported equivalent), and only users who are familiar with the terminal. If you satisfy the above criteria, read on.
Hi all, I've just discovered that disabling the second core of my Xperia go's CPU actually improves overall UI responsiveness in JB rather than the contrary, despite logic dictating otherwise. In fact, it's so smooth now that I can safely say it directly rivals GB's smoothness and response times (and this is from a long term GB user who just recently made the jump to JB, too).
I'm making this thread because I'd like to see if others will experience similar effects from disabling the second CPU core of their NovaThor U8500 SoCs.
Disclaimer: I am not responsible for anything in the unlikely event that you - somehow - break your phone from making this small tweak. Just saying. You should be fine if you follow the instructions, though.
You have to be running on battery power to be able to spot any difference since the UI's sluggishness isn't as noticable when connected to a power source. Oh, and leave your governor / clock speed settings at stock (i.e. interactive governor, 200 MHz min, 1000 MHz max) for a fairer comparison.
Open up a terminal window, then enter Superuser / root mode and enter the following command:
Code:
echo [B]0[/B] > /sys/devices/system/cpu/cpu[B]1[/B]/online
(that's a ZERO immediately after echo and a ONE in /cpu/cpu1)
This should immediately take the second core offline, you can verify it with the following command (do consider first opening an additional new terminal window for this purpose):
Code:
cat /proc/kmsg
Look for something along the lines of:
Code:
<5>[35017.521636] CPU1: shutdown
Now, start testing the responsiveness of the UI, it should be extremely smooth in comparison to what it normally is. Skeptics, please do feel free to drop your jaws at this point, because I sure did when I first tried this. I noticed that the processor's speed seemed to ramp up and down much more aggressively with the second core disabled, but that could just be me seeing things.
To re-enable the secondary core again, use this command:
Code:
echo [B]1[/B] > /sys/devices/system/cpu/cpu[B]1[/B]/online
(that's a ONE immediately after echo and a ONE in /cpu/cpu1)
You can verify that the core is enabled in the dmesg logs (remember the earlier cat /proc/kmsg command?):
Code:
<4>[35155.743408] CPU1: Booted secondary processor
<6>[35155.745011] Switched to NOHz mode on CPU #1
At this point, you're likely to see the sluggishness make a return.
This should be fairly obvious, but don't go doing "smart" (that was sarcasm, in case you missed it the first time) stuff like disabling the first core (or even both) because you'd clearly be asking for trouble.
I suspect that the presence of the second core is preventing the governor from ramping up the processor speed on battery power, leading to the sluggish UI response. It has been noted before that a pair of cores running at a lower clock speed can potentially be more power efficient than a single core running at a higher clock speed, so I'm not too sure how this would affect the phone's battery life. I haven't yet noticed any negative impacts of the change on battery life - if anything, battery life appears to be improved, but I'd like more people to test this out (preferably those on P, U and sola phones).

There is an app to do this.
Enviado desde mi ST25i usando Tapatalk 2

Diego910 said:
There is an app to do this.
Enviado desde mi ST25i usando Tapatalk 2
Click to expand...
Click to collapse
But in Xcore app the second core turns on automatically after sometime..
Does dat happen with the terminal method?!
Sent from my ST25i

In X-Core, after disabling the core, go to superuser app nd toggle permissions for X-Core... Second core doesn't switch on fr me that way...
Press thanks if I helped :thumbup:

dotafan said:
In X-Core, after disabling the core, go to superuser app nd toggle permissions for X-Core... Second core doesn't switch on fr me that way...
Press thanks if I helped :thumbup:
Click to expand...
Click to collapse
Tried it but in vain..
Sent from my ST25i

weired..

Related

[Q] Dual Core /proc/stats

I've been working on building a dual core cpu meter for the atrix. I have a very very basic APK that reads your /proc/stats and displays it. I have noticed that on launch cpu 1 shows up and exists but after a few ticks, it's no longer there... I'm not saying that the phone isn't using it. I'd simply like to know why it's disappearing.. Sorry in advance if I posted in the wrong forum.
Edit: Is it safe to assume that since the core isnt being shown in the proc stats at certain intervals that the core is being put into a sort of 'standby' mode until a thread is passed to it? If so, could I default that core to 0% cpu usage when not shown.
Just a thought - do something to up your CPU, maybe spawn a couple processes to eat up some CPU cycles and see what happens?
mister_al said:
Just a thought - do something to up your CPU, maybe spawn a couple processes to eat up some CPU cycles and see what happens?
Click to expand...
Click to collapse
To max out kernel CPU time
cat /dev/zero > /dev/null

[Q] Major Battery Drain While Using Words With Friends

I recently installed words with friends and have noticed a major drain on my battery caused by it slamming my cpu and RAM. All it is, is a scrabble type of game but continues to BASH my phone in the background. I have never experienced such drain from any game let alone a game that is not very graphic based. Something strange is happening here.
Has anybody else had the same issue? I don't remember it draining my battery as bad on my SGS 1.......
https://market.android.com/details?id=com.zynga.words&feature=search_result
Edit: Found this: http://androidforums.com/android-games/277995-beware-words-friends-eating-up-battery.html
The problem is happening on my best mates iPhone too
Its probably the apps code. Its making the phone run both cores at Max for no reason.
If your a root user try underclocking to 800 and see if its still bad.
Sent from my GT-I9100 using XDA App
Change background notifications to never in the account setting page. Also force close it in the battery status screen.
Sent from my GT-I9100 using XDA Premium App
Same thing happens to me. My phone gets so hot and my battery drains like crazy whenever I play the game. I wish the Developers would fix it, cause I love playing this game!
I use task killers (e.g., Advance Task Killer) to autokill the app when the phone is off, because sometimes the app still runs in the background. And whenever I turn my phone back on my battery is almost dead.
It's the problem with the app itself and until they fix the problem I'm keeping it away from my Android phone, that's lame.
Words is just a pain but my ios friends play it ...
What I do with mine is have a rooted phone and have tasker and have to cripple the phone to 500mhz max so it's still playable, just not speedy or it'll sit at 1000mhz looking at the game board but the waiting for moves screen can sit at 200mhz displaying ads
profile is words
entry
1. notify, "words running"
2. notify cancel, "words running"
3. cpu, gov powersave 500-500mhz
4. wait, 1second until %cpufreq < 510000
5. if, %cpufreq > 500000
6. goto 3
7. endif
8. cpu, gov conservative 200-500mhz
9. if, cpu > 500000
10. cpu powersave 500-500
11. endif
12. notify if %cpufreq < 510000, "throttled - max 500" with a icon of a hippo
exit
1. cpu gov, on demand 200-1200
2. notify cancel "throttled - max 500"
i also have a shortcut to task that launches words, just sets the gov to conservative 200-500 and loads words, the cpu freq won't stay at your max if it's already over the maximum
it loses smooth scrolling around the game board but uses half or less of the battery it did just running as is. when words isn't in the foreground it'll go back to whatever you set it to
Found this searching for my own issue. Just killing the app after closing it didn't help enough because it would still drain while I had it open.
Using the AT&T version I get the same issue. WordFeud's footprint is literally non-existant so I would suggest moving to that app. It's on iOS too.
I think they finally fixed it with the new words update
tallblazer124 said:
I think they finally fixed it with the new words update
Click to expand...
Click to collapse
Still seems to be killing me on a Droid PRO

System power saving actually useful?

Hi guys!
I've noticed recently a new power save get option in the power saving menu in settings called 'system power saving'.
I've never seen much point in using the specific power saving mode that you can set to kick in at x% because it doesn't seem to do anything I can't and don't do manually myself.
Does anyone know anything about this new setting? Turning it on i've noticed screen transitions are a little less smooth, but does this actually do anything useful?
Any ideas?
Many thanks!
Sent from my GT-I9100 using XDA App
I would be interested in finding out what this does as well.
I noticed that frame rates seemed lower in games, and the responsiveness is a little slower (not considerably, though).
Is there a list of what it actually does?
I've notice that my phone uses less battery in this mode that without it.
MrThomsen said:
I've notice that my phone uses less battery in this mode that without it.
Click to expand...
Click to collapse
Well, I would hope so...
I do know that it does NOT disable background data (I still receive push emails with both Exchange and Gmail)
Camera and Auto-flash are still enabled.
Everything that typically gets turned off in order to save battery is still on as far as I can tell...
We know it saves battery... but how?
If we find out how, then our developers could probably leverage that information when making new ROMs.
I would just like to know if anything is being disabled that I don't want disabled... but I don't know what I don't know
It lowers the CPU clock frequency, in my SGSII, scrolling desktops is not smooth at all with this option ON I've never been patient enough to test this option for a long time
when i activate powersaving it doesnt seem to make a difference
elmo180 said:
It lowers the CPU clock frequency, in my SGSII, scrolling desktops is not smooth at all with this option ON I've never been patient enough to test this option for a long time
Click to expand...
Click to collapse
Seriously?
I have mine overclocked to 1.6 GHz and the conservative governor and I have not noticed the time-in-state data to be changing from what it was without this option set.
You were right about the clock speed.
system power save does the following:
Restricts core speed (mine was capped at 800)
Lowers brightness
Changes UI frame rate
Warning: Created with Swype

Bug Reports

There doesn't seem to be any bug report thread on English forum, only other languages so thought it would be a good idea to post this.
Here is some bugs I've noticed, mainly related to performance.
-When you open notifications and switch to toggles, the animation is not smooth first time.
-The transition effects except default seem laggy, especially windmill. Not like this on my other Honor phone with significantly less powerful cpu.
-When you scroll to end/top of page, such as in play store or phone settings, then tap on something right away, the tap is not registered. You must wait until 'end of scroll' animation completes. Not like this on other phones I've tried.
- In balanced power mode, opening some apps such as phone dialer or browser causes the brightness to drop. Kind of annoying. The power modes should only affect the cpu.
Storage space lost after update from b100 to b121 bug.
I updated my phone before using it and storage space dropped from around 9.8gb to 9.1gb.
Space seemed to have been taken up by apps according to the storage info, but no additional apps were installed. Must be a bug where after the update, the app optimization made the phone think previously installed apps were installed again.
A power mode should only affect the cpu? Why? Its job is to save power so doing it in other ways to just cpu throttling is perfectly logical.
Sent from my PLK-L01 using Tapatalk
mgolder said:
A power mode should only affect the cpu? Why? Its job is to save power so doing it in other ways to just cpu throttling is perfectly logical.
Sent from my PLK-L01 using Tapatalk
Click to expand...
Click to collapse
That's how the power mode worked before in EMU, and the brightness transition is glitchy and unsightly. It also mentions nothing about brightness changes in description, just cpu adjustments.
Most people like to set their own brightness, having it lower when you open the browser/dialer is just annoying and pointless. You can easily change brightness yourself but not how the cpu scales.

[HELP] [KERNEL] Why there are 4 separate sections for schedtune.prefer_idle?

From my understanding, Kernels that have schedutil governor has a CPU frequency boosting feature which gives the CPU a push from the back to do a job faster than it was supposed to.
It does make the phone notably faster and smoother but if not configured properly the battery takes a hit.
Enabling schedtune.prefer_idle turns off that frequency boost of a running core and forces the workload on an idle core. But there seem to be 4 separate options to enable schedtune.prefer_idle and I have no idea what they are and how they are gonna affect the kernel after enabling/disabling
Those 4 options are :
• Foreground
• Background
• Real-Time
• Top App
Here are the pictures if you want to take a look.
https://imgur.com/a/sxuBvWR
https://imgur.com/a/8e4nuxj
Can someone tell me what each function does? Thanks in advance
@TrenchFullOfSlime can you help me out one more time if possible?
schedtune.prefer_idle appears to influence only one thing: whether a process will share time on an already-active core or wake up an idle core. The latter uses more power but gives the process more resources. CPU frequencies are determined by the _boost toggles, with schedtune.boost determining how aggressively the frequency is changed (accepted values are 0-100, so I guess it's an abstract scale hiding the actual size of the frequency steps). This apparently works by lying to the governor about how heavy a process is: https://lwn.net/Articles/706374/
https://forum.xda-developers.com/t/...-pixel-xl-and-eas-even-more-smoother.3528807/ suggests not going over 10.
https://forum.xda-developers.com/t/screen-on-time.3923963/page-9 suggests "turning off prefer.idle and enabling stune.boost reduced power use by 15% without affecting responsiveness" (paraphrased). Turning both on could increase responsiveness at the cost of greater power use, turning both off would do the opposite.
As for the different categories, they determine what triggers this behavior. You might prioritize performance for foreground apps, but battery efficiency for background apps. It can also be used to increase boot times: https://source.android.com/devices/tech/perf/boot-times
More information: https://www.fatalerrors.org/a/schedtune-learning-notes.html
TrenchFullOfSlime said:
schedtune.prefer_idle appears to influence only one thing: whether a process will share time on an already-active core or wake up an idle core. The latter uses more power but gives the process more resources. CPU frequencies are determined by the _boost toggles, with schedtune.boost determining how aggressively the frequency is changed (accepted values are 0-100, so I guess it's an abstract scale hiding the actual size of the frequency steps). This apparently works by lying to the governor about how heavy a process is: https://lwn.net/Articles/706374/
https://forum.xda-developers.com/t/...-pixel-xl-and-eas-even-more-smoother.3528807/ suggests not going over 10.
https://forum.xda-developers.com/t/screen-on-time.3923963/page-9 suggests "turning off prefer.idle and enabling stune.boost reduced power use by 15% without affecting responsiveness" (paraphrased). Turning both on could increase responsiveness at the cost of greater power use, turning both off would do the opposite.
As for the different categories, they determine what triggers this behavior. You might prioritize performance for foreground apps, but battery efficiency for background apps. It can also be used to increase boot times: https://source.android.com/devices/tech/perf/boot-times
More information: https://www.fatalerrors.org/a/schedtune-learning-notes.html
Click to expand...
Click to collapse
I don't know who you are, I don't know what you do but I feel like you are an angel! You went through all the troubles to get those links only to answer me which made me so happy.
If I'm being honest, the way you describe things is incredible. I didn't have to read a sentence twice. You can be a good writer or a teacher if you try.
Thank you so much

Categories

Resources