Yes the script has a little issue. I am debugging it now. I will post the fix soon as am done testing...
-Resolved Linux-swap not turning on
-VM configuration works with Linux-swap
-Compcache works with any kernel version
-Ensure backing_swap is not always the default
-Minimum CPU scaling frequency
-CPU sampling rate (You should not touch this unless you know why it was added and what it means)
The fix/update is now posted. I take no credit for this script.
adb push userinit.sh /system/sd
adb push user.conf /system/sd
To use only linux-swap
To use only compcache without backing_swap
-set cc_disksize=32 (32*1024 = 32768kb = 32MB)
To use compcache with backing_swap
-set cc_disksize=0 (doesn't really matter so long cc_memlimit != 0)
-set cc_memlimit=8 (doesn't matter the number used, it will default to 15% of total RAM--known issue)
These are default system settings:
sampling_rate=2000000 (200000 depending on kernel version)
I have updated the script and start a new post http://forum.xda-developers.com/showthread.php?p=4240913#post4240913
if there are anything you guys wanna to add.. just le me know. I am happy to do it.