Merge lp:~verzegnassi-stefano/ubuntu-docviewer-app/workaround-fix-1432412 into lp:ubuntu-docviewer-app/trunk

Proposed by Stefano Verzegnassi
Status: Merged
Approved by: Stefano Verzegnassi
Approved revision: 107
Merged at revision: 107
Proposed branch: lp:~verzegnassi-stefano/ubuntu-docviewer-app/workaround-fix-1432412
Merge into: lp:ubuntu-docviewer-app/trunk
Diff against target: 48 lines (+10/-4)
2 files modified
po/com.ubuntu.docviewer.pot (+3/-3)
src/plugin/poppler-qml-plugin/pdfdocument.cpp (+7/-1)
To merge this branch: bzr merge lp:~verzegnassi-stefano/ubuntu-docviewer-app/workaround-fix-1432412
Reviewer Review Type Date Requested Status
Alan Pope 🍺🐧🐱 πŸ¦„ (community) Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+254117@code.launchpad.net

Commit message

Workaround for multi-core support on ARM SoCs

Description of the change

Workaround for multi-core support on ARM SoCs

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Alan Pope 🍺🐧🐱 πŸ¦„ (popey) wrote :

Tested on bq device and works fine. We may need to re-visit on meizu device (which runs vivid, and a newer kernel) because it seems to never spin more than 1 core even under heavy load in this app.

For now, I say approve as bq device is only one shipping, and we can analyse meizu/vivid issue separately.

review: Approve
Revision history for this message
Stefano Verzegnassi (verzegnassi-stefano) wrote :

Ok, I top-approve it then.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'po/com.ubuntu.docviewer.pot'
2--- po/com.ubuntu.docviewer.pot 2015-03-12 19:00:33 +0000
3+++ po/com.ubuntu.docviewer.pot 2015-03-25 16:54:00 +0000
4@@ -8,7 +8,7 @@
5 msgstr ""
6 "Project-Id-Version: \n"
7 "Report-Msgid-Bugs-To: \n"
8-"POT-Creation-Date: 2015-03-12 19:59+0100\n"
9+"POT-Creation-Date: 2015-03-25 17:51+0100\n"
10 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
11 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
12 "Language-Team: LANGUAGE <LL@li.org>\n"
13@@ -189,7 +189,7 @@
14 msgstr ""
15
16 #: ../src/app/qml/documentPage/DocumentPage.qml:25
17-#: /home/stefano/tmp/translations/build-ubuntu-docviewer-app-Desktop-Default/po/com.ubuntu.docviewer.desktop.in.in.h:1
18+#: /home/stefano/Progetti/doc-viewer/build-ubuntu-docviewer-app-Desktop-Default/po/com.ubuntu.docviewer.desktop.in.in.h:1
19 msgid "Document Viewer"
20 msgstr ""
21
22@@ -254,6 +254,6 @@
23 msgid "Loading..."
24 msgstr ""
25
26-#: /home/stefano/tmp/translations/build-ubuntu-docviewer-app-Desktop-Default/po/com.ubuntu.docviewer.desktop.in.in.h:2
27+#: /home/stefano/Progetti/doc-viewer/build-ubuntu-docviewer-app-Desktop-Default/po/com.ubuntu.docviewer.desktop.in.in.h:2
28 msgid "documents;viewer;pdf;reader;"
29 msgstr ""
30
31=== modified file 'src/plugin/poppler-qml-plugin/pdfdocument.cpp'
32--- src/plugin/poppler-qml-plugin/pdfdocument.cpp 2015-02-04 19:19:21 +0000
33+++ src/plugin/poppler-qml-plugin/pdfdocument.cpp 2015-03-25 16:54:00 +0000
34@@ -174,7 +174,13 @@
35 // WORKAROUND: QQuickImageProvider should create multiple threads to load more images at the same time.
36 // [QTBUG-37998] QQuickImageProvider can block its separate thread with ForceAsynchronousImageLoading
37 // Link: https://bugreports.qt.io/browse/QTBUG-37988
38- int newProvidersNumber = QThread::idealThreadCount();
39+
40+ // WORKAROUND: ARM SoCs can disable some of their cores when the load is not particulary high.
41+ // This causes a wrong value for the "newProvidersNumber" variable.
42+ // We hard-code its value to 4 (which is the number of available core on all the supported devices).
43+// int newProvidersNumber = QThread::idealThreadCount();
44+ int newProvidersNumber = 4;
45+
46 if (newProvidersNumber != m_providersNumber) {
47 m_providersNumber = newProvidersNumber;
48 Q_EMIT providersNumberChanged();

Subscribers

People subscribed via source and target branches