Priority: Not Evaluated
Affects Version/s: 4.8.3
Fix Version/s: None
CPU: MIPS 24k
RAM: 128 MB (~28MB allocated by system & initramfs)
Linux Kernel: 22.214.171.124
After some time (a few minutes) typical web browsing, browser application (QtWebKit based browser - both demo browser and arora) starts to experience significant slowdown in responsiveness, page loading and rendering speed. Eventually application will be killed by Kernel because of out of memory. First clue was found using top application which showed high kernel IO usage (90 - 100%). That led to tweaking all caches we could find in WebKit engine either decreasing or completely disabling them using following function calls or setting variable values:
QWebSettings::setObjectCacheCapacities(0, 0, 0);
QPixmapCache::setCacheLimit(1024); //for embedded systems default is 2048
QNetworkReplyPrivate::QNetworkReplyPrivate(): readBufferMaxSize(32768) // default is 0 which means unlimited
static const int cDefaultCacheCapacity = 512 * 1024; // changed from default value: 8192 * 1024
After that, repetitive function calls:
showed that there are no cached resources. Still, slowdown and high kernel IO are being experienced.
Reading blog article The effect of TCmalloc in the QtWebKit port - stage 2: Memory consumption led us to disabling TCmalloc allocator and falling back to default system malloc:
#define USE_SYSTEM_MALLOC 1
which again, didn't resolve issues.
Since our system doesn't have swap, final and again unsuccessful attempt was made tuning Linux system parameter:
echo 0 > /proc/sys/vm/swappiness
Our conclusion is that this could be Qt related problem since running Android and its WebKit based browser on exactly the same HW platform doesn't have these issues at all.
System log is attached.