[Android Software/Hacking General [Developers Only]] smokin1337:
This gives a really nice boost to performance. I use it in my rom and thought i would share.

Just put them in init.d

02sicktweaks:

#!/system/bin/sh
#Sick Tweaks

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

setprop ro.telephony.call_ring.delay 0
setprop ring.delay 0
#setprop windowsmgr.max_events_per_sec 100
setprop windowsmgr.support_rotation_270 true
setprop ro.HOME_APP_ADJ 1
setprop ro.HOME_APP_MEM 2048
setprop dalvik.vm.heapsize 72m

06sysctl:

#!/system/bin/sh
#sysctl stuff

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