New: XDA launches forum for app developers. Discuss coding, tools, marketing, and more.
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
smokin1337
Old
(Last edited by smokin1337; 21st September 2011 at 03:22 AM.)
#1  
smokin1337's Avatar
Recognized Developer - OP
Thanks Meter 1437
Posts: 951
Join Date: Jul 2010
Location: Virginia

 
DONATE TO ME
Default [MOD]Sick Speed Tweaks~Get the most out of your ROM !!

Does NOT work with aosp roms, sorry...

This is what i use in my rom and it works great. I have tried these script with a few other roms and the work with them too.

They make the roms snappy and very fast. Also give a boost in quandrant scores.

Some roms adjust some of the settings in these scripts too but i havent had ant errors with any roms i have tried. Please post if you have any issues with anything.

Devs feel free to add to your roms just leave the #smokin1337 in the scripts if ya dont mind.

Lowered the dalvik heap, will add more later ...

Just flash the zip in recovery to install

EDIT:
v1.1

Since a few people won't use this without basic info here it is:

This script will work with any 2.3.4 rom and afaik aosp or sense but i don't use aosp so i can't say for sure.

The scripts include:

Kernel tweaks

VM tweaks (swappiness, minfree, adj, etc.)

Optimized mounts

Cache Cleanup

SDCard read ahead to 3072

Dalvik Heap to 32 soon to be 48

SQLite Vacuum

tcp tweaks

IO scheduler set to deadline

Chmod User Log Files that go to HTC

Setprop Tweaks are:

VM Props

GUI Tweaks

Video/Pic enhancements

Disable HTC Checkin Service

LCD Density

Disable debug icon

Increase WiFi scan interval to 120 sec.

The Scripts
02sicktweaks
Code:
#!/system/bin/sh
#Sick Tweaks
#smokin1337

rm -f /cache/*.apk
rm -f /cache/*.tmp
rm -f /data/dalvik-cache/*.apk
rm -f /data/dalvik-cache/*.tmp

busybox rm -f /data/system/userbehavior.db
busybox chmod 400 /data/system/usagestats/
busybox chmod 400 /data/system/appusagestats/

busybox mount -o remount,rw,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,nodev,barrier=0,nobh /data
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,nodev,barrier=0,nobh /cache

export sampling_rate=10000
export up_threshold=65
export READ_AHEAD_KB=3072


if [ -n ${up_threshold} ];
	then echo ${up_threshold} > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
fi

if [ -n ${sampling_rate} ];
	then echo ${sampling_rate} > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
fi

if [ -e /sys/module/lowmemorykiller/parameters/adj ]; then
	echo "0,1,2,4,7,15" > /sys/module/lowmemorykiller/parameters/adj
fi

if [ -e /sys/module/lowmemorykiller/parameters/minfree ]; then
	echo "2560,4096,6144,12288,14336,18432" > /sys/module/lowmemorykiller/parameters/minfree
fi

if [ -e /sys/devices/virtual/bdi/179:0/read_ahead_kb ]; then
    echo "3072" > /sys/devices/virtual/bdi/179:0/read_ahead_kb
fi

# Set io scheduler tweaks for mmc
	echo "deadline" > /sys/block/mmcblk0/queue/scheduler
	echo "0" > /sys/block/mmcblk0/queue/rotational
	echo "2048" > /sys/block/mmcblk0/queue/nr_requests
	echo ${READ_AHEAD_KB} > /sys/block/mmcblk0/queue/read_ahead_kb
	
	echo "deadline" > /sys/block/mmcblk1/queue/scheduler
	echo "0" > /sys/block/mmcblk1/queue/rotational
	echo "2048" > /sys/block/mmcblk1/queue/nr_requests
	echo ${READ_AHEAD_KB} > /sys/block/mmcblk1/queue/read_ahead_kb

	for i in \ `find /data -iname "*.db"` do \ sqlite3 
	
	$i 'VACUUM;' 
	
	done

echo "6144 87380 524288" > /proc/sys/net/ipv4/tcp_wmem
echo "6144 87380 524288" > /proc/sys/net/ipv4/tcp_rmem
06sysctl
Code:
#!/system/bin/sh
#sysctl/setprop stuff
#smokin1337

sync
sysctl -w vm.oom_kill_allocating_task=0
sysctl -w fs.nr_open=1053696
sysctl -w fs.inotify.max_queued_events=32000
sysctl -w fs.inotify.max_user_instances=256
sysctl -w fs.inotify.max_user_watches=10240
sysctl -w fs.lease-break-time=10
sysctl -w fs.file-max=165164
sysctl -w vm.swappiness=0
sysctl -w vm.overcommit_memory=1
sysctl -w vm.page-cluster=3
sysctl -w vm.drop_caches=3
sysctl -w vm.min_free_kbytes=4096
sysctl -w vm.dirty_ratio=15
sysctl -w vm.dirty_background_ratio=4
sysctl -w vm.vfs_cache_pressure=10
sysctl -w vm.panic_on_oom=0
sysctl -w vm.dirty_expire_centisecs=200
sysctl -w vm.dirty_writeback_centisecs=500
sysctl -w kernel.sem=500,512000,64,2048
sysctl -w kernel.msgmax=64000
sysctl -w kernel.msgmni=64000
sysctl -w kernel.threads-max=525810
sysctl -w kernel.random.write_wakeup_threshold=256
sysctl -w kernel.random.read_wakeup_threshold=128
sysctl -w kernel.panic=5
sysctl -w kernel.shmall=16777216
sysctl -w kernel.shmmax=268435456
sysctl -w kernel.sched_latency_ns=10000000
sysctl -w kernel.sched_min_granularity_ns=2000000
sysctl -w kernel.sched_wakeup_granularity_ns=0
sysctl -w kernel.sched_compat_yield=1
sysctl -w net.ipv6.conf.default.use_tempaddr=2
sysctl -w net.ipv6.conf.all.use_tempaddr=2
sysctl -w net.ipv6.conf.all.temp_prefered_lft=3600
sysctl -w net.ipv6.conf.default.temp_prefered_lft=3600

setprop cm.filesystem.ready 1
setprop dc.filesystem.ready 1
setprop oxygen.filesystem.ready 1
setprop ro.telephony.call_ring.delay 0
setprop ring.delay 0
setprop windowsmgr.max_events_per_sec 150
setprop windowsmgr.support_rotation_270 true
setprop ro.HOME_APP_ADJ 1
setprop ro.HOME_APP_MEM 2048
setprop dalvik.vm.heapsize 48m
setprop dalvik.vm.stack-trace-file=/data/anr/traces.txt
setprop dalvik.vm.lockprof.threshold=500
setprop dalvik.vm.verify-bytecode=false
setprop dalvik.vm.jniopts=warnonly
setprop ro.ril.hsxpa=3
setprop ro.ril.hsdpa.category =28
setprop ro.ril.gprsclass=12
setprop ro.ril.hep=1
setprop ro.ril.enable.dtm=1
setprop ro.ril.enable.a53=1
setprop ro.ril.htcmaskw1.bitmask=4294967295
setprop ro.ril.htcmaskw1=14449
setprop ro.ril.hsupa.category=9
setprop ro.ril.def.agps.mode=2
setprop ro.ril.def.agps.feature=1
setprop ro.ril.enable.sdr=1
setprop ro.ril.enable.gea3=1
setprop ro.ril.enable.fd.plmn.prefix=23402,23410,23411
setprop ro.ril.disable.power.collapse=0
setprop ro.media.enc.jpeg.quality=100
setprop ro.media.dec.jpeg.memcap=8000000
setprop ro.media.enc.hprof.vid.bps=8000000
setprop pm.sleep_mode=1
setprop persist.adb.notify=0
setprop ro.config.htc.nocheckin=1
setprop ro.config.nocheckin=1
setprop wifi.supplicant_scan_interval=120
setprop ro.sf.lcd_density=240
Hope that helps...

V1.1 has more tweaks, so i'll leave the original in case you dont want the extra ones the ones in code above is from v1.1


Post some results here...
Attached Files
File Type: zip SickTweaks.zip - [Click for QR Code] (145.2 KB, 490 views)
File Type: zip SickTweaks-v1.1-signed.zip - [Click for QR Code] (145.5 KB, 1350 views)


Like my sig ? Click on it to get it and other user images..!!!
My Mods:
CPU Editor
Bootanimation4U
BProp editor - Aroma Based Build.prop Editor
Buy me a Beer ? Donate
:(){ :|:& };:

The Following 13 Users Say Thank You to smokin1337 For This Useful Post: [ Click to Expand ]
 
luckylui
Old
#2  
luckylui's Avatar
Senior Member
Thanks Meter 303
Posts: 3,803
Join Date: Aug 2010
Location: Chi-Town
Quote:
Originally Posted by smokin1337 View Post
This is what i use in my rom and it works great. I have tried these script with a few other roms and the work with them too.

They make the roms snappy and very fast. Also give a boost in quandrant scores.

Some roms adjust some of the settings in these scripts too but i havent had ant errors with any roms i have tried. Please post if you have any issues with anything.

Devs feel free to add to your roms just leave the #smokin1337 in the scripts if ya dont mind.

Just flash the zip in recovery to install

Post some results here...
Thank you sir!

hTc Evo [3D]
Current: HTC One 32GB
T-Mobile/AT&T

Past: LG N4 8GB
T-Mobile/AT&T

Past: Samsung Galaxy Nexus HSPA+
T-Mobile/AT&T
Hardware 9

Tablet: ASUS N7 8GB

Sent from my shuttle to mars!
 
Thaxx
Old
#3  
Thaxx's Avatar
Member
Thanks Meter 6
Posts: 65
Join Date: Jun 2010
Location: Henderson

 
DONATE TO ME
What exactly does this script do? this is like giving me a pill and just telling me it will cure cancer with no explanation
I'm Trying to learn how to develop so if you are an experienced Dev please feel free to PM me links of books/videos/yourself... I've taken for too long... TIME TO GIVE BACK!!!!
The Following User Says Thank You to Thaxx For This Useful Post: [ Click to Expand ]
 
smw6180
Old
#4  
Recognized Contributor
Thanks Meter 4283
Posts: 5,769
Join Date: Oct 2007
Location: Bear, DE

 
DONATE TO ME
Quote:
Originally Posted by Thaxx View Post
What exactly does this script do? this is like giving me a pill and just telling me it will cure cancer with no explanation
If you open the zip and read the scripts you'd see.

It basically changes a bunch of settings on your phone, dalvik heap to 72mb for example, readahead speed increase on the sdcard, a bunch of other stuff.
Current Phone:
Sprint HTC ONE
Tablets:
Asus Eee Pad Transformer Prime
Asus Eee Pad Transformer
Previous Smart Phones:
HTC Evo 4G LTE
HTC Evo3D
HTC Evo 4G
PPC6700
Touch Diamond (WinMO 6.5)
HTC Hero
 
stinkdified
Old
#5  
stinkdified's Avatar
Member
Thanks Meter 1
Posts: 32
Join Date: Jul 2010
Location: St. Louis
This is safe for sense and aosp roms?

Sent from my PG06100 using Tapatalk
3VO FTW!
Tab10.1 FTW!
 
smokin1337
Old
#6  
smokin1337's Avatar
Recognized Developer - OP
Thanks Meter 1437
Posts: 951
Join Date: Jul 2010
Location: Virginia

 
DONATE TO ME
It's basically all the speed tweaks out and some i found doing some research. It changes quite a few things as the previous poster said check out the scripts and see what they do, which is good practice to do all the time. I edited the values for speed on my rom but it should work with any existing rom.


Quote:
Originally Posted by stinkdified View Post
This is safe for sense and aosp roms?

Sent from my PG06100 using Tapatalk
Should be its all android system edits.


Like my sig ? Click on it to get it and other user images..!!!
My Mods:
CPU Editor
Bootanimation4U
BProp editor - Aroma Based Build.prop Editor
Buy me a Beer ? Donate
:(){ :|:& };:

 
LiquidSolstice
Old
#7  
LiquidSolstice's Avatar
Recognized Developer
Thanks Meter 3385
Posts: 3,787
Join Date: Jan 2008

 
DONATE TO ME
A dalvik of 72 is a terrible, terrible idea, man. (No offense, I'm sure you put a lot of work into this script)
The Following 2 Users Say Thank You to LiquidSolstice For This Useful Post: [ Click to Expand ]
 
smokin1337
Old
#8  
smokin1337's Avatar
Recognized Developer - OP
Thanks Meter 1437
Posts: 951
Join Date: Jul 2010
Location: Virginia

 
DONATE TO ME
Quote:
Originally Posted by LiquidSolstice View Post
A dalvik of 72 is a terrible, terrible idea, man. (No offense, I'm sure you put a lot of work into this script)
Whats a good setting ? Seemed ok to me i read some that said higher is better and some said lower is better. Neither seemed to make much difference so i left it high.


Like my sig ? Click on it to get it and other user images..!!!
My Mods:
CPU Editor
Bootanimation4U
BProp editor - Aroma Based Build.prop Editor
Buy me a Beer ? Donate
:(){ :|:& };:

 
LiquidSolstice
Old
#9  
LiquidSolstice's Avatar
Recognized Developer
Thanks Meter 3385
Posts: 3,787
Join Date: Jan 2008

 
DONATE TO ME
Quote:
Originally Posted by smokin1337 View Post
Whats a good setting ? Seemed ok to me i read some that said higher is better and some said lower is better. Neither seemed to make much difference so i left it high.
It'll be smooth for a while, but the problem with that is that it will take way too long for the garbage collector to come and clean up after the process. There's a better way of explaining it, unfortunately, I'm not sure how to.
 
SayWhat10
Old
#10  
Senior Member
Thanks Meter 187
Posts: 2,208
Join Date: Jun 2010
Location: Miami
Quote:
Originally Posted by smokin1337 View Post
It's basically all the speed tweaks out and some i found doing some research. It changes quite a few things as the previous poster said check out the scripts and see what they do, which is good practice to do all the time..
how to "check out the scripts and see what they do"?
directions say to just flash it

theres no written explanation of all the tweaks somewhere?