Decreasing RAM allocated to user?

Search This thread

Codename13

Senior Member
Jun 22, 2012
935
1,307
A serious question: I have a low-end device (single-core 1 GHz CPU) that has 768 MB RAM in total. However, only 645 MB out of the 768 MB is available to the user (the rest is used for the system). I previously tried increasing the RAM allocated to the user from 645 MB to 660 MB, but it caused a lot of lag and instability. That convinces me that if I was to increase the RAM allocated to the system (which would result in decreasing the RAM allocated to the user), would there be less lag? Would decreasing the user RAM cause any issues? Of course, the best thing is for me to try it out first, but I want to hear some opinions on what I'm thinking. If 645 MB of RAM is available to the user with stock RAM tunings, then that means there is about 123 MB of RAM allocated to the system. Below is the current code for the RAM allocating stuff from my device's board file in the kernel source. Note that my device has CONFIG_ARCH_MSM7X27A and CONFIG_MACH_KYLE and CONFIG_FB_MSM_TRIPLE_BUFFER enabled in its defconfig:
#ifdef CONFIG_ARCH_MSM7X27A
#define MSM_PMEM_MDP_SIZE 0x2300000
#if defined(CONFIG_MACH_KYLE)
#define MSM_PMEM_ADSP_SIZE 0x1200000
#else
#define MSM_PMEM_ADSP_SIZE 0x1100000
#endif
#if CONFIG_FB_MSM_TRIPLE_BUFFER
/* prim = 320 x 480 x 4(bpp) x 3(pages) */
#define MSM_FB_SIZE (800 * 480 * 4 * 3)
#else
/* prim = 320 x 480 x 4(bpp) x 2(pages) */
#define MSM_FB_SIZE (800 * 480 * 4 * 2)
#endif /* CONFIG_FB_MSM_TRIPLE_BUFFER */
#else
#define MSM_PMEM_MDP_SIZE 0x1DD1000
#define MSM_PMEM_ADSP_SIZE 0x1000000
#define MSM_FB_SIZE 0x195000
#endif /* CONFIG_ARCH_MSM7X27A */
Thank you to whoever gives me some insight
 
Last edited: