[HTC Wildfire S] baluuu:
So here is The init.d script 99WFStweaks

And a shell script to add lines to build prop Build.prop.sh

This is like really half assed work tough I think I got it runing on boot but i havent had the chance to test for performance improvement, also I took the optimizations as is and didnt bother looking for the optimal WFS values so enjoy my ****ty work lol.

I used this thread as a guidline so thank to optik19918

Here is the code.

99WFStweaks

#!/system/bin/sh
#WFS Tweaks
#Internet speed twaks
echo "0" > /proc/sys/net/ipv4/tcp_timestamps;
echo "1" > /proc/sys/net/ipv4/tcp_tw_reuse;
echo "1" > /proc/sys/net/ipv4/tcp_sack;
echo "1" > /proc/sys/net/ipv4/tcp_tw_recycle;
echo "1" > /proc/sys/net/ipv4/tcp_window_scaling;
echo "5" > /proc/sys/net/ipv4/tcp_keepalive_probes;
echo "30" > /proc/sys/net/ipv4/tcp_keepalive_intvl;
echo "30" > /proc/sys/net/ipv4/tcp_fin_timeout;
echo "404480" > /proc/sys/net/core/wmem_max;
echo "404480" > /proc/sys/net/core/rmem_max;
echo "256960" > /proc/sys/net/core/rmem_default;
echo "256960" > /proc/sys/net/core/wmem_default;
echo "4096,16384,404480" > /proc/sys/net/ipv4/tcp_wmem;
echo "4096,87380,404480" > /proc/sys/net/ipv4/tcp_rmem;

#VM mamagement tweaks
echo "4096" > /proc/sys/vm/min_free_kbytes
echo "0" > /proc/sys/vm/oom_kill_allocating_task;
echo "0" > /proc/sys/vm/panic_on_oom;
echo "0" > /proc/sys/vm/laptop_mode;
echo "0" > /proc/sys/vm/swappiness;
echo "50" > /proc/sys/vm/vfs_cache_pressure;
echo "90" > /proc/sys/vm/dirty_ratio;
echo "70" > /proc/sys/vm/dirty_background_ratio;

#Battery Tweaks
echo "500" > /proc/sys/vm/dirty_expire_centisecs;
echo "1000" > /proc/sys/vm/dirty_writeback_centisecs;

#Ext4 tweaks
tune2fs -o journal_data_writeback /dev/block/mtdblock3;
tune2fs -O ^has_journal /dev/block/mtdblock3;
tune2fs -o journal_data_writeback /dev/block/mtdblock4;
tune2fs -O ^has_journal /dev/block/mtdblock4;
tune2fs -o journal_data_writeback /dev/block/mtdblock5;
tune2fs -O ^has_journal /dev/block/mtdblock5;
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /data;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /cache;

#Flags blocks as non-rotational and increases cache size
LOOP=`ls -d /sys/block/loop*`;
RAM=`ls -d /sys/block/ram*`;
MMC=`ls -d /sys/block/mmc*`;
for j in $LOOP $RAM
do
echo "0" > $j/queue/rotational;
echo "2048" > $j/queue/read_ahead_kb;
done;

#MicroSD speed fix
echo "2048" > /sys/devices/virtual/bdi/179:0/read_ahead_kb;

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

#Removes logger
rm /dev/log/main

Build.prop.sh

#!/system/bin/sh
#Build.prop tweaks
echo "ro.media.enc.jpeg.quality=100" >> /system/build.prop;
echo "dalvik.vm.heapsize=48m" >> /system/build.prop;
echo "debug.sf.hw=1" >> /system/build.prop;
echo "ro.telephony.call_ring.delay=0" >> /system/build.prop;
echo "windowsmgr.max_events_per_sec=150" >> /system/build.prop;
echo "wifi.supplicant_scan_interval=180" >> /system/build.prop;
echo "pm.sleep_mode=1" >> /system/build.prop;
echo "ro.ril.disable.power.collapse=0" >> /system/build.prop;
echo "debug.performance.tuning=1" >> /system/build.prop;
echo "video.accelerate.hw=1" >> /system/build.prop;
echo "ro.media.dec.jpeg.memcap=12000000" >> /system/build.prop;
echo "ro.media.enc.hprof.vid.bps=12000000" >> /system/build.prop;
echo "ro.ril.hsxpa=2" >> /system/build.prop;
echo "ro.ril.gprsclass=10" >> /system/build.prop;
echo "ro.ril.hep=1" >> /system/build.prop;
echo "ro.ril.enable.dtm=1" >> /system/build.prop;
echo "ro.ril.hsdpa.category=10" >> /system/build.prop;
echo "ro.ril.enable.a53=1" >> /system/build.prop;
echo "ro.ril.enable.3g.prefix=1" >> /system/build.prop;
echo "ro.ril.htcmaskw1.bitmask=4294967295" >> /system/build.prop;
echo "ro.ril.htcmaskw1=14449" >> /system/build.prop;
echo "ro.ril.hsupa.category=5" >> /system/build.prop;
echo "net.tcp.buffersize.default=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.wifi=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.umts=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.gprs=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.edge=4096,87380,256960,4096,16384,256960" >> /system/build.prop;