Skip to main content
It’s essential to configure your device’s basic settings before analyzing system performance. The settings play a significant role in the performance of the device. You can configure the CPU, GPU, and memory settings.
Any configuration changes can impact the power and the performance of the device. Ensure that you verify the impact across all relevant use cases before any modifications.

Configure CPU

You can check and modify the CPU configurations using the commands specified in the following table:
The commands specified in the following table should be run on the device. The unit of the output value for these commands is in KHz.
The commands containing policy7 aren’t supported on QCS5430 FP1.
To configure a CPU for Qualcomm Dragonwing IQ-9075 and Qualcomm Dragonwing IQ-8275, see the corresponding addendum: Table : Commands to configure the CPU for QCS6490, QCS5430 FP2, FP2.5, FP3 You can check and modify the CPU configurations for Qualcomm Dragonwing IQ-615 using the commands specified in the following table: Table : Commands to configure the CPU for Dragonwing IQ-615

Configure GPU

You can check and modify the GPU configurations on the device using the commands specified in the following table:
The commands specified in the following table should be run on the device. The unit of the output value for these commands is in Hz.
Table : Commands to configure the GPU

Configure memory

Memory configuration is crucial to conserve memory, make space available for processes, and balance the existing data in RAM when the physical memory reaches its limits.

Set ZRAM disk size

ZRAM is a RAM partition to swap memory space. It stores the inactive anonymous pages in a compressed form in RAM to conserve memory. The ZRAM disk size indicates the maximum amount of memory that can be swapped from RAM to ZRAM. It’s recommended to set the ZRAM disk size to half the size of RAM. ZRAM is enabled by default in the Qualcomm® Linux® build. By default, 50% of RAM is configured as the ZRAM memory limit using the /sys/block/zram*/mem_limit parameter in the post_boot_common.sh script. To reconfigure the ZRAM memory limit, modify the /sys/block/zram*/mem_limit parameter value in the post_boot_common.sh script located at /etc/urm/initscripts/post_boot/ on the device. For more information about the post-boot scripts, see Post-boot init scripts.

Enable/disable proactive compaction

Compaction is a process that collects all the free memory spaces in the form of fragments into a large memory block. Proactive compaction determines the level of aggressiveness with which memory compaction happens in the background. It accepts a value between 0 and 100, with the default value set to 20. When the fragmentation score of the node exceeds a high threshold, the corresponding kcompactd thread initiates the proactive compaction process. The compaction process remains active until the score of the node falls below the low threshold. The thresholds for proactive compaction are as follows:
  • Low = 100 - proactiveness
  • High = low + 10%
For instance, if the low threshold is 80, the high threshold would be 90. To enable proactive compaction, run the following command on the device:
To disable proactive compaction, which also turns off the periodic kcompactd wake-ups, run the following command on the device:
For more information, see Proactive compaction for the kernel.

Swappiness

Swap space is a secondary storage that functions similar to the main memory or RAM. The primary parameter of swap space is swappiness.
  • This parameter determines how aggressively the kernel swap daemon (kswapd) swaps out anonymous memory relative to the system page cache.
  • This parameter can take a value between 0 and 200. Increasing the value augments the amount of anonymous swapping. The configured value is 100, indicating that both anonymous and cache memories are reclaimed equally.
To adjust the swappiness value, run the following command on the device:
For more information about memory parameters, see Documentation for /proc/sys/vm/.

Next steps