init.rc: Tune F2FS and dirty writeout policy for modern devices
In a previous commitbb0838b511, the gc_urgent_sleep_time for F2FS was aggressively set to 50ms to optimize GC. This change, however, led to performance regressions on most devices, particularly of those running in 4.19+ kernels. From our tests, the heightened CPU and I/O activity from this aggressive garbage collection setting is the likely cause. To address this, we're revising the gc_urgent_sleep_time parameter to strike a balance between aggressive GC and device performance, takingbb0838b511goal into consideration. Furthermore, the dirty writeout policy has been aligned with the latest configurations used in Pixel devices, and cp_interval has been adjusted to surpass dirty_expire_centisecs for improved power efficiency during idle times. Test: booted partner device, monitor performance Change-Id: Ie4d0c870d734e915aaebcc53e64acdabac47b6dc Signed-off-by: minaripenguin <minaripenguin@users.noreply.github.com>
This commit is contained in:
parent
0d071119a0
commit
367e295c4b
1 changed files with 4 additions and 2 deletions
|
|
@ -1190,10 +1190,12 @@ on boot
|
|||
# to avoid power consumption when system becomes mostly idle. Be careful
|
||||
# to make it too large, since it may bring userdata loss, if they
|
||||
# are not aware of using fsync()/sync() to prepare sudden power-cut.
|
||||
write /dev/sys/fs/by-name/userdata/cp_interval 200
|
||||
write /dev/sys/fs/by-name/userdata/gc_urgent_sleep_time 50
|
||||
write /dev/sys/fs/by-name/userdata/cp_interval 6000
|
||||
write /dev/sys/fs/by-name/userdata/gc_urgent_sleep_time 200
|
||||
write /dev/sys/fs/by-name/userdata/iostat_period_ms 1000
|
||||
write /dev/sys/fs/by-name/userdata/iostat_enable 0
|
||||
write /proc/sys/vm/dirty_expire_centisecs 3000
|
||||
write /proc/sys/vm/dirty_background_ratio 10
|
||||
|
||||
# set readahead multiplier for POSIX_FADV_SEQUENTIAL files
|
||||
write /dev/sys/fs/by-name/userdata/seq_file_ra_mul 128
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue