yashsingh1/xdaforums huggingface dataset:
[Nexus 7 Original Development] Geko45:
99% of the time you would be correct, but there is a specific issue with grouper and talapia that this works around. These devices were originally sold at the incredible price point of about $300. In order to achieve that target price, they used inferior quality solid state storage chips that suffered from horrendous IO latency. It was so bad that any ROM after KitKat was practically unusable on these devices (as in apps would hang for minutes at a time when they tried to do just about anything even remotely storage intensive).

In order to breath new life into these tablets, ParrotGeek came up with his now famous ParrotMod which makes a number tweaks to work around this issue (like zRAM and setting noatime and much more). That combined with other tweaks like disabling logcat and using f2fs made these devices usable again. ParrotMod was so successful that some ROM developers (like Anddisa) incorporated these enhancements directly into their ROMs.

Of course, the aim of this project is to be as pure AOSP as possible (but with a 3.4 kernel). So, I applied ParrotGeek's orignal optimization script and that helped a lot (on top of what the 3.4 kernel did to improve performance), but I was still experiencing lags, stutters, FCs, and even the occasional spontaneous reboot. Fixing the RAM disk section of the ParrotMod script has all but eliminated these issues for me and the tablet is now rock solid and nearly as smooth as it was new running KitKat. Yes, it would be even better if zRAM were available in this 3.4 kernel, but it's not. So, regular RAM disk is the next best thing.

In short, the RAM disk in ParrotMod was never really about extending RAM via zRAM compression, it was about giving the kernel a place to which to swap that wasn't plagued by the horrible IO latency of the solid state storage. That's the source of nearly all the lagginess for these old tablets. Backed up storage writes that bring the whole system to a halt until the chips can catch up with the workload.

ParrotGeek's original thread: https://xdaforums.com/nexus-7/orig-development/parrotmod-speed-2012-nexus-7-emmc-fix-t3300416
[Nexus 7 Original Development] adstraylight:
Thanks for this, it does seem to smooth things out, even with just your code running in its own script. I did try adding it to an old adaption of the PM script, which caused some instability which I'm guessing was something to do with other changes in that script.

How have you implimented it, did you just flash the latest PM and simply relace the section of code? Are you using the busybox version that comes as part of PM?

I should note that this works well coupled with an app called SSD Boost, which mainly remounts the file system with a noatime flag to reduce io overhead. I'm usually quite wary of so called booster type apps, but that one is pretty effective.

I agree that ZRAM would be favorable as the compression would add to the RAM capacity, but I'm not sure if it's even possible on k3.4, and also understand that the UA guys want to keep things as straight forward as possible.
[Nexus 7 Original Development] AdriK:
[MENTION=2583740]adstraylight[/MENTION],

I think ZRAM shuold be possible with kernel 3.4.x, it's just a case of adding it to the config and configuring it.

I guess [MENTION=2633638]Ziyan[/MENTION] would have to do this and provide a new image.

[MENTION=4201184]Geko45[/MENTION],

I know about slow solid state flash etc., but that has nothing to do with memory and swapping, only reading and writing from the filesystems.

I'd love to hear your explanation why reserving a block off memory for swap and when you run out of the remaining memory earlier, copying to this reserved block of memory to free up memory, is going to speed up things. These are all memory operations and don't involve and solid state flash chips.

If you never reserve any memory for swap, all the original memory is always available, so you will delay the need for swapping.
[Nexus 7 Original Development] sheffzor:
Depends on how swappiness is configured!! [emoji28]

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] adstraylight:
True, while playing with swappiness on other ROMs I found the sweet spot was 47, in terms of smoothness and stability, apparently google recommends 60, but parotgeek thought that too much, his default was around 50 iirc.
[Nexus 7 Original Development] aaopt:
Thanks [MENTION=562996]AdriK[/MENTION] for spelling it out so I don't have to.

[MENTION=4201184]Geko45[/MENTION] it seems you have some experimental evidence to support your claim. Your results are fascinating... but I am having trouble imagining why it helps. Maybe if we can understand what we are missing we might find a different setting which has a similar effect without being counter-intuitive.
[Nexus 7 Original Development] aaopt:
The 100+ pages is the problem. ParrotMod contains a lot of stuff and it wasn't obvious how many pages we would have to read to find the part related to your proposed changes. So thanks for boiling that down for us. Still somewhat counter-intuitive (that you make it run better by making it run out of memory faster) but sometimes that's life.
[Nexus 7 Original Development] Geko45:
Or one could actually walk through ParrotGeek's original script to see what it is really doing (like I did).

Sorry if I seemed abrupt but Adrisk was toting the standard Android party line without understanding there is a specific problem with these devices that is attempting to be addressed. The way Android handles memory and storage works great if you are on decent hardware that can be counted on to perform adequately, but that's not the case with the Nexus 7. The high IO latency of these devices have been their bane since Lollipop first came out.
[Nexus 7 Original Development] Geko45:
It's important to note that I am doing this on the Marshmallow/3.4 release, not the Nougat/3.4 one. The instabilities you describe might be from some other aspects of the ParrotMod script that aren't Nougat compatible.

All I did was flash ParrotMod to the MM/3.4 release provided here and then convert the zRAM disk to a normal RAM disk. I have also taken some of the build.prop settings from AndDiSa's 6.0 ROM and that also seems to be helping.

Right now, the only issue I am having with the MM/3.4/talapia combo is that the broadband radio sometimes dies and requires a reboot for it to come back.
[Nexus 7 Original Development] adstraylight:
That makes sense, I'm running ypur ramdisk with nougat, as I say it's working well alongside SSD Boost. I'm also using a taskiller to shut down non essential apps when the screen is off, & so far so good.
[Nexus 7 Original Development] Geko45:
Rather than using a third party app killer, I do something similar with a build.prop edit. The setting ro.sys.fw.bg_apps_limit will change the default number of background apps that Android will keep in memory without affecting system services. Plus, you save yourself the need of having one more service running for the task killer itself.

Also, SSD Boost does two things that really help. One is running an fstrim on the filesystems and the other is setting noatime and then remounting them. The former makes the empty space immediately available for use and the latter prevents the kernel from generating a write to update the last access time attribute of a file or directory whenever it is read. It is certainly possible to do both of these in the same boot script without even needing the overhead of third party tools. ParrotMod already does the fstrim for instance.

Here, try this. It's mostly borrowed from ParrotMod, but only the safe bits that should work on Nougat no problem. That, and I added noatime and my previous ramdisk script (I've only tested this on Marshmallow though):
[Nexus 7 Original Development] adstraylight:
I keep getting syntax errors when trying to run your script, I guess this may be to do with bb version, anyway, what I'm using achieves pretty much the same thing..

I like using the taskiller app as it allows me to choose which apps get killed, eg I rarely use maps, which is a resource hog, but have much more frequent need of say Gmail. I can also keep useful stuff like gboard memory resident for fast recall.
[Nexus 7 Original Development] Geko45:
Interesting. I'm staying on MM with my Talapia device as I really like my Xposed mods, but I have a Grouper device just sitting around too. I might throw this kernel and Nougat on that one to play with.
[Nexus 7 Original Development] adstraylight:
That would be useful, as it's very problematic to bugfix by remote, as I've seen many comedies of errors play out here, I look forward to your insight if you choose to do this. It could also be the way I'm running the script, I'm using (yes you guessed it) another app called init.d scripts support out of convenience/habit, and this may be playing a role.
[Nexus 7 Original Development] namerke:
Regarding the ongoing conversation about ZRAM: yes, it's possible for sure to have ZRAM with kernel 3.4 .

I'm no dev, but I've already made a personal kernel build from unlegacy-android sources, added and enabled backported ZRAM and ZSMALLOC from kernel 3.10 (basically cherry-picked them from [MENTION=3292224]franciscofranco[/MENTION] 's nexus 5 3.4 kernel sources), I've also added and enabled SDCARDFS to reduce the IO overhead even more. I've also added some ramdisk changes to to benefit from parrot's and [MENTION=2188693]AndDiSa[/MENTION] 's modifications and to enable F2FS on both cache and data partitions.

Since I don't know if [MENTION=2633638]Ziyan[/MENTION] and [MENTION=4619263]sheffzor[/MENTION] would be ok with it I won't share my build here, I respect the countless hours they have put into this project and I don't want to steal credit from anyone.

Also, SDCARDFS is still pretty much a bleeding edge feature.

Based on my experiences these changes can have positive effects on the performance, so I encourage anyone who is willing to experiment with some self made builds and enjoy the benefits.
[Nexus 7 Original Development] Sage:
You should ask permission your kernel sounds very good indeed! (i'd like to have a try!)
[Nexus 7 Original Development] Ziyan:
Feel free to publish the build. Then we can as well speak about adding those changes (through our Gerrit) :)
[Nexus 7 Original Development] abhifx:
Very interesting. If you can post your kernel in a separate thread then i am sure lots of people will be interested. If this can somewhat fix the lags to an extent then we have a fully capable tablet in hand
[Nexus 7 Original Development] AndDiSa:
... there is another reason why probably the 3.4 kernel should become the basis for further Grouper/Tilapia development: Magisk-hide

For the 3.4 kernel it should be more easy to add namespace mount support than for the 3.1 kernel and namespace mount support is a precondition that Magisk-hide hide works
[Nexus 7 Original Development] namerke:
:good:

Since I'll have to share source code once I share the compiled build I'm going to push my changes to GitHub first and once that is done I'll open another thread to avoid user complaints in this one. Please be patient.
[Nexus 7 Original Development] abhifx:
i am having trouble miracasting n7 to a chinese miracast dongle.. anyone knows the fix?
[Nexus 7 Original Development] adstraylight:
There's a line in the parrotmod script that might help:

#enable miracast

setprop persist.debug.wfd.enable 1

Could be worth a try running it in a terminal emulator thus:

su

setprop persist.debug.wfd.enable 1

Caveat: not tried it myself....
[Nexus 7 Original Development] abhifx:
i can already see the miracast device, however it fails to connect.

not to mention that even through dlna and airplay.. things dont go smooth at all. anybody with better understanding with wifi on grouper?
[Nexus 7 Original Development] namerke:
Follow up on this post: My personal build was way ahead with more than necessary commits for you guys, therefore I've gone ahead and made a less customized version with only SDCRADFS and ZRAM&ZSMALLOC added and enabled . Even the ramdisk scripts have been removed for now. This way we can find out if my changes are stable enough on their own. You can still achieve re-mounts and trim via your scripts / respective apps, but initially I'd like to avoid any unnecessary complaints.

But you can find out about these information and even more in the topic that I opened to follow up on my build:

[ALPHA][3.4][ZRAM][SDCARDFS]Experimental Nexus 7 kernel build

!!! I highly recommend you to read everything in the OP to avoid any confusion / errors. !!!
[Nexus 7 Original Development] abhifx:
nice.. this with [MENTION=4201184]Geko45[/MENTION] script should theoretically fix random freeze and reboot.
[Nexus 7 Original Development] adstraylight:
At the urging of a fellow user, and even though I'm running namerke's experimental Alpha kernel, I've decided to post my configuration here on the off chance it may be of use to others, or be helpful to the devs..

Via Kernel Auditor:

200MB Zram (swappiness 100)

interactive governor parameters:

CPU quiet policy: 'runnable'

'boost_factor' 0

'go_maxspeed_load' 80

'midrange_go_maxspeed_load' 90

'min_sample_time' 50000

'timer_rate' 50000

Build.prop parameter : 'ro.wifi.channels' 13 (default for the UK, other regions vary, seems to reduce dropouts & make wifi generally more stable, by default this parameter has no value assigned)

SSD Boost app (NB. If like me, you have a kingston internal SD, then this may cause your grouper to take a long time to start properly, as it trims the SD on startup, but I think it's worth it due to the reduced io overhead it provides via its noatime remounting of the SD)

Via init.d support app running this command at startup: service call

SurfaceFlinger 1009 i32 1

(old habit - suggestion of parrotgeek's to speed up rendering of transparency)

Also this:

echo 2 > /sys/block/zram0/max_comp_streams

(so there is always CPU available for things other than Zram compression/decompression)

Dev Options: force gpu rendering (just a thought to relieve some CPU load).

With the above I have a smooth running stable device that doesn't freeze/lockup, NB. Zram is currently not available with the default kernel so will not be of relevance. All of the above have been arrived at through a combination of googling/trial and error, and all I can say is it works for me, so it will be interesting to know if it is of use to anyone else.
[Nexus 7 Original Development] adstraylight:
Here's (perhaps) an interesting question for the devs.

I, like 8% of men, am partially color blind, in my case it's the red/green type. This can be compensated for in the android settings, both Accessibility and Dev Options, but on th N7 it causes graphical lags.

On my N4, it doesn't affect the performance at all, so I was wondering if this could be addressed?

It's probably a blob thing, but I thought I'd ask....

I should add that it always has been this way, and isn't an issue for this ROM in particular.
[Nexus 7 Original Development] HTCDreamOn:
I think Android implements the colour change at quite a low level (i.e. it's not just a filter). Perhaps a temporary solution would be an app which simply has a filter overlay like those nighttime filters? I expect the general problem is something to do with the gpu though.
[Nexus 7 Original Development] adstraylight:
It's not a huge deal per se, after all unenhanced the screen looks like the rest of my world?

I just like the vibrancy the 'corrected' version brings.

As the feature appeared after the grouper's release, I just wondered if part of the graphics subsystem needed to be specifically ported to the N7.
[Nexus 7 Original Development] Gopi dubstrom:
Bro can u send me the link because this link is showing that file has been deleted or

can u send me the link because this link is showing that file has been deleted or disabled for 3.4 Kernal for Nexus 7 2012 can u can send me link
[Nexus 7 Original Development] adstraylight:
An observation, very occasionally I have problems switching from one WiFi AP to another, the connection gets stuck on 'obtaining ip address'. This can be resolved by clearing the recents screen.
[Nexus 7 Original Development] adstraylight:
Great news, the UA guys have added a fork to their git for the big O! The mind boggles at the possibility of my dear old grouper being able to run A8....?

Apologies for the ot, but it is a rather tantalising prospect...

Keep up the fantastic work guys, it's truly appreciated!
[Nexus 7 Original Development] abhifx:
wonder if we will get enhanced Bluetooth audio and low latency lock screen as well.
[Nexus 7 Original Development] julianctni:
The Download Links for TWRP do not work anymore. :( Just flashed it with TWRP 3.1.1 but it is not able to install the GAPPS. During flash process everything seems to work but after boot it says "process system not working" and it starts a naked android without any gapps
[Nexus 7 Original Development] adstraylight:
After flashing the ROM, go into the Mount section of TWRP, and uncheck System.

Then flash Gapps.

The System not working happens to me occasionally on first boot, sometimes needs an emergency reboot to get past. I think this is because of the very high background workload on the first boot.

Also let the the ROM and gaaps run for a while before flashing supersu, for the same reason. I just think care has to be taken due to the limited system resources of such an old tablet running such a modern os.

The k3.4 recovery links have been dead for ages, in fact the entire OP is out of date, but I guess the devs have much more fun things to do ?

Btw, I suggest you also take a look at my post detailing my config on the previous page, as it really does help with the whole user experience when running this ROM. It involves flashing namerke's experimental kernel, but that's fantastic anyway, so well worth it in itself.

Hope this helps and have fun!
[Nexus 7 Original Development] romskii:
I'm about to use a Nexus 7 in my car and I'm happy about this project. Nice job!
[Nexus 7 Original Development] massima:
Is possible to use this ROM for a daily use??? I have cache and data formatted with F2FS and i don't use gapps.

Thanks
[Nexus 7 Original Development] DumF0rGaming:
I had an issue running this with F2FS until I wiped cache and data to ext4, maybe because of kernel freezes on tilapia. AFAIK it should support F2FS for data only.
[Nexus 7 Original Development] massima:
Right!!! It didn't boot with cache in F2FS format, in ext4 format it booted successfully. Data partition is still in F2FS format.

I disabled the search bar but it is visible.
[Nexus 7 Original Development] adstraylight:
Getting a lot of log spam about the camera server failing.

Also got a very weird problem with the YouTube app not installing properly, cant figure what is going on, but I think they (Google) just added a whole bunch of permissions to it that causes the system to block it altogether, even when I explicitly grant them in the apps settings, not a huge thing as the web interface works, so have uninstalled the app.

But did wonder if the two could be connected....
[Nexus 7 Original Development] adstraylight:
Here are the YouTube logs...
[Nexus 7 Original Development] kalafior12:
What date (build) of this rom do you use?

B.T.W. link to tha latest buils is broken...

Regards

Wysłane z mojego Nexus 7 przy użyciu Tapatalka
[Nexus 7 Original Development] massima:
I used the version dated 28 august and everything went smooth. Try again!!!
[Nexus 7 Original Development] adstraylight:
I agree, I'm using the latest release listed on the Unlegacy Android site.
[Nexus 7 Original Development] eNVy:
Will it work on Lineage OS ?
[Nexus 7 Original Development] adstraylight:
No, the thread title is somewhat misleading, as the kernel needs it's own custom ROM to work properly. So the download is a ROM and Kernel package. There is an experimental version of the kernel as well, but this can only be used with the Unlegacy Android ROM.
[Nexus 7 Original Development] Cocalarix:
So how is the kernel + that ROM so far? Good for daily usage or is it still too buggy?
[Nexus 7 Original Development] adstraylight:
I think it's great when paired with namerke's custom kernel, and my personal settings. Otherwise it is prone to occasional lockups caused by what I perceive to be spikes in background cpu load, and the simple realities of not enough RAM and slow io.

But as I say, most of this can be worked around, so as it is, with some fine tuning, it's fine as a "daily driver".
[Nexus 7 Original Development] kalafior12:
Do You have

Data on f2fs

Cache and system on ext4 ?

Or everything on ext4 ?

Wysłane z mojego LG-D855 przy użyciu Tapatalka
[Nexus 7 Original Development] massima:
Only data is in f2fs format.
[Nexus 7 Original Development] Bert98:
You mean that the YouTube app isn't loading anything at all? Because I'm having the same issue with the latest release
[Nexus 7 Original Development] adstraylight:
Yep, it opens, but just sits there with the spinner spinning, and doesn't load any content. I've tried clean flashing the ROM, different gapps packages, and it's still the same.
[Nexus 7 Original Development] Bert98:
Same, I even tried reverting to the 22/08 build but same issues
[Nexus 7 Original Development] dirtyreturn:
Hey there.

Is that custom kernel on this site??

---------- Post added at 02:23 PM ---------- Previous post was at 02:21 PM ----------

Got it!

Thanks for reporting its a good combination with this rom!
[Nexus 7 Original Development] kalafior12:
I've implemented Your settings but I'm not sure int.d method. Could you write instruction for dummies where in kernel audithor is the right place? and what about other settings ? Are You applying at boot?:

I/O sheduler

Low memory killer (medium, aggressive?)

Kernel samepage merging

Entrophy

Regards

Wysłane z mojego LG-D855 przy użyciu Tapatalka
[Nexus 7 Original Development] adstraylight:
Everything at default values apart from the ones I stated, yes apply on boot if that suits you, it is what I do and helps with any possible lockups at boot when the CPU load is high.

With the init.d app, you just put the lines in a text file in its own folder on your internal storage, tell the app to look for that folder, and run the script with su privileges. If you want to make it a proper script, just rename the text file from .txt to .sh, but the app will run .txt files as scripts unless you tell it not to. Again I have this set to execute at boot for convenience.

Edit: you'll notice that some of the CPU governor values are already set to be what I recommend in the latest version of the custom Kernel.

I should add that these settings are simply what works best for me, and with a bit of time, use and study, you may find other tweaks that work for you better, in which case it would be great if you, or anyone else could post them.
[Nexus 7 Original Development] kalafior12:
#!/system/bin/sh

SurfaceFlinger 1009 i32 1

echo 2 > /sys/block/zram0/max_comp_streams

May this lines implemented via int.d section in tools in kernel auditor?

Wysłane z mojego Nexus 7 przy użyciu Tapatalka
[Nexus 7 Original Development] adstraylight:
Last time I tried that it didn't seem to work, but there have been a few updates to KA since then. I use the init.d support app out of habit, and because I'm just more familiar with it. I also like its feature of being able to display the last execution results, which is very useful when experimenting with different settings.

I suggest you just try it to see, do report your results, as I agree it would be simpler to implement everything in the one app.

The method I use has evolved over time, so may not be the most efficient ?
[Nexus 7 Original Development] adstraylight:
Still getting a weird problem running the YouTube app on the latest build, I've attached the install log for the app as it has an error regarding a missing package.

If anyone knows more I'd be grateful..
[Nexus 7 Original Development] DumF0rGaming:
[MENTION=2633638]Ziyan[/MENTION] Do you have any internal progress with Oreo?