[arch-commits] Commit in kdebase-workspace (5 files)

Andrea Scarpino andrea at archlinux.org
Sun Sep 11 10:02:16 UTC 2011


    Date: Sunday, September 11, 2011 @ 06:02:16
  Author: andrea
Revision: 137800

Apply important performance bugfix patch for kwin effects

Added:
  kdebase-workspace/repos/extra-i686/important-performance-bugfix.patch
  kdebase-workspace/repos/extra-x86_64/important-performance-bugfix.patch
  kdebase-workspace/trunk/important-performance-bugfix.patch
Modified:
  kdebase-workspace/repos/extra-i686/PKGBUILD
  kdebase-workspace/trunk/PKGBUILD

-------------------------------------------------------+
 repos/extra-i686/PKGBUILD                             |   11 +
 repos/extra-i686/important-performance-bugfix.patch   |   91 ++++++++++++++++
 repos/extra-x86_64/important-performance-bugfix.patch |   91 ++++++++++++++++
 trunk/PKGBUILD                                        |   11 +
 trunk/important-performance-bugfix.patch              |   91 ++++++++++++++++
 5 files changed, 289 insertions(+), 6 deletions(-)

Modified: repos/extra-i686/PKGBUILD
===================================================================
--- repos/extra-i686/PKGBUILD	2011-09-11 09:52:06 UTC (rev 137799)
+++ repos/extra-i686/PKGBUILD	2011-09-11 10:02:16 UTC (rev 137800)
@@ -5,7 +5,7 @@
 pkgname=kdebase-workspace
 _pkgname=kde-workspace
 pkgver=4.7.1
-pkgrel=4
+pkgrel=6
 pkgdesc="KDE Base Workspace"
 arch=('i686' 'x86_64')
 url='http://www.kde.org'
@@ -30,7 +30,8 @@
 options=('emptydirs')
 source=("http://download.kde.org/stable/${pkgver}/src/${_pkgname}-${pkgver}.tar.bz2"
         'kdm-zsh-profile.patch' 'kdm' 'kde.pam' 'kde-np.pam' 'kscreensaver.pam'
-        'fixpath.patch' 'terminate-server.patch')
+        'fixpath.patch' 'terminate-server.patch'
+        'important-performance-bugfix.patch')
 sha1sums=('c7867d2f788086078abbcff53a035a6131232539'
           '8c2bdefb23a03b753b78d16944d03fa3939d2d99'
           '5db3a245201bd4a50e65aa2ef583cf5490e4f646'
@@ -38,7 +39,8 @@
           '603cc79c4d2b4eae62bb5f244aeecb3a778b5516'
           '106635aa1aae51d6f0668b1853f6c49a4fe9d3d8'
           'd7b5883f7e65c6839b1f65f94d58026673dd0226'
-          'ac7bc292c865bc1ab8c02e6341aa7aeaf1a3eeee')
+          'ac7bc292c865bc1ab8c02e6341aa7aeaf1a3eeee'
+          '4fa046db21e3203771fd29bc0e1c32918862b894')
 
 build() {
 	cd ${srcdir}/${_pkgname}-${pkgver}
@@ -46,6 +48,9 @@
 	patch -p0 -i ${srcdir}/fixpath.patch
 	patch -p0 -i ${srcdir}/terminate-server.patch
 
+    # Already fixed upstream
+    patch -p1 -i "${srcdir}"/important-performance-bugfix.patch
+
 	cd ${srcdir}
 	mkdir build
 	cd build

Added: repos/extra-i686/important-performance-bugfix.patch
===================================================================
--- repos/extra-i686/important-performance-bugfix.patch	                        (rev 0)
+++ repos/extra-i686/important-performance-bugfix.patch	2011-09-11 10:02:16 UTC (rev 137800)
@@ -0,0 +1,91 @@
+commit e142a1a142cbc8b87f021223e6abc947f456a7f9
+Author: Thomas Lübking <thomas.luebking at gmail.com>
+Date:   Thu Sep 8 22:20:35 2011 +0200
+
+    replace non-const QVector::operator[] accesses with const ::at() to avoid maaany deep vecor copies
+
+diff --git a/kwin/effects.cpp b/kwin/effects.cpp
+index e0c76cb..f5863fc0 100644
+--- a/kwin/effects.cpp
++++ b/kwin/effects.cpp
+@@ -200,7 +200,7 @@ void EffectsHandlerImpl::reconfigure()
+ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->prePaintScreen(data, time);
++        loaded_effects.at(current_paint_screen++).second->prePaintScreen(data, time);
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -209,7 +209,7 @@ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData& data)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->paintScreen(mask, region, data);
++        loaded_effects.at(current_paint_screen++).second->paintScreen(mask, region, data);
+         --current_paint_screen;
+     } else
+         scene->finalPaintScreen(mask, region, data);
+@@ -218,7 +218,7 @@ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData&
+ void EffectsHandlerImpl::postPaintScreen()
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->postPaintScreen();
++        loaded_effects.at(current_paint_screen++).second->postPaintScreen();
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -227,7 +227,7 @@ void EffectsHandlerImpl::postPaintScreen()
+ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& data, int time)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->prePaintWindow(w, data, time);
++        loaded_effects.at(current_paint_window++).second->prePaintWindow(w, data, time);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -236,7 +236,7 @@ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& dat
+ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->paintWindow(w, mask, region, data);
++        loaded_effects.at(current_paint_window++).second->paintWindow(w, mask, region, data);
+         --current_paint_window;
+     } else
+         scene->finalPaintWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -245,7 +245,7 @@ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region,
+ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, double opacity, double frameOpacity)
+ {
+     if (current_paint_effectframe < loaded_effects.size()) {
+-        loaded_effects[current_paint_effectframe++].second->paintEffectFrame(frame, region, opacity, frameOpacity);
++        loaded_effects.at(current_paint_effectframe++).second->paintEffectFrame(frame, region, opacity, frameOpacity);
+         --current_paint_effectframe;
+     } else {
+         const EffectFrameImpl* frameImpl = static_cast<const EffectFrameImpl*>(frame);
+@@ -256,7 +256,7 @@ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, do
+ void EffectsHandlerImpl::postPaintWindow(EffectWindow* w)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->postPaintWindow(w);
++        loaded_effects.at(current_paint_window++).second->postPaintWindow(w);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -273,7 +273,7 @@ bool EffectsHandlerImpl::provides(Effect::Feature ef)
+ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_draw_window < loaded_effects.size()) {
+-        loaded_effects[current_draw_window++].second->drawWindow(w, mask, region, data);
++        loaded_effects.at(current_draw_window++).second->drawWindow(w, mask, region, data);
+         --current_draw_window;
+     } else
+         scene->finalDrawWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -282,7 +282,7 @@ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, W
+ void EffectsHandlerImpl::buildQuads(EffectWindow* w, WindowQuadList& quadList)
+ {
+     if (current_build_quads < loaded_effects.size()) {
+-        loaded_effects[current_build_quads++].second->buildQuads(w, quadList);
++        loaded_effects.at(current_build_quads++).second->buildQuads(w, quadList);
+         --current_build_quads;
+     }
+ }

Added: repos/extra-x86_64/important-performance-bugfix.patch
===================================================================
--- repos/extra-x86_64/important-performance-bugfix.patch	                        (rev 0)
+++ repos/extra-x86_64/important-performance-bugfix.patch	2011-09-11 10:02:16 UTC (rev 137800)
@@ -0,0 +1,91 @@
+commit e142a1a142cbc8b87f021223e6abc947f456a7f9
+Author: Thomas Lübking <thomas.luebking at gmail.com>
+Date:   Thu Sep 8 22:20:35 2011 +0200
+
+    replace non-const QVector::operator[] accesses with const ::at() to avoid maaany deep vecor copies
+
+diff --git a/kwin/effects.cpp b/kwin/effects.cpp
+index e0c76cb..f5863fc0 100644
+--- a/kwin/effects.cpp
++++ b/kwin/effects.cpp
+@@ -200,7 +200,7 @@ void EffectsHandlerImpl::reconfigure()
+ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->prePaintScreen(data, time);
++        loaded_effects.at(current_paint_screen++).second->prePaintScreen(data, time);
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -209,7 +209,7 @@ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData& data)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->paintScreen(mask, region, data);
++        loaded_effects.at(current_paint_screen++).second->paintScreen(mask, region, data);
+         --current_paint_screen;
+     } else
+         scene->finalPaintScreen(mask, region, data);
+@@ -218,7 +218,7 @@ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData&
+ void EffectsHandlerImpl::postPaintScreen()
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->postPaintScreen();
++        loaded_effects.at(current_paint_screen++).second->postPaintScreen();
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -227,7 +227,7 @@ void EffectsHandlerImpl::postPaintScreen()
+ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& data, int time)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->prePaintWindow(w, data, time);
++        loaded_effects.at(current_paint_window++).second->prePaintWindow(w, data, time);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -236,7 +236,7 @@ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& dat
+ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->paintWindow(w, mask, region, data);
++        loaded_effects.at(current_paint_window++).second->paintWindow(w, mask, region, data);
+         --current_paint_window;
+     } else
+         scene->finalPaintWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -245,7 +245,7 @@ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region,
+ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, double opacity, double frameOpacity)
+ {
+     if (current_paint_effectframe < loaded_effects.size()) {
+-        loaded_effects[current_paint_effectframe++].second->paintEffectFrame(frame, region, opacity, frameOpacity);
++        loaded_effects.at(current_paint_effectframe++).second->paintEffectFrame(frame, region, opacity, frameOpacity);
+         --current_paint_effectframe;
+     } else {
+         const EffectFrameImpl* frameImpl = static_cast<const EffectFrameImpl*>(frame);
+@@ -256,7 +256,7 @@ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, do
+ void EffectsHandlerImpl::postPaintWindow(EffectWindow* w)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->postPaintWindow(w);
++        loaded_effects.at(current_paint_window++).second->postPaintWindow(w);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -273,7 +273,7 @@ bool EffectsHandlerImpl::provides(Effect::Feature ef)
+ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_draw_window < loaded_effects.size()) {
+-        loaded_effects[current_draw_window++].second->drawWindow(w, mask, region, data);
++        loaded_effects.at(current_draw_window++).second->drawWindow(w, mask, region, data);
+         --current_draw_window;
+     } else
+         scene->finalDrawWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -282,7 +282,7 @@ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, W
+ void EffectsHandlerImpl::buildQuads(EffectWindow* w, WindowQuadList& quadList)
+ {
+     if (current_build_quads < loaded_effects.size()) {
+-        loaded_effects[current_build_quads++].second->buildQuads(w, quadList);
++        loaded_effects.at(current_build_quads++).second->buildQuads(w, quadList);
+         --current_build_quads;
+     }
+ }

Modified: trunk/PKGBUILD
===================================================================
--- trunk/PKGBUILD	2011-09-11 09:52:06 UTC (rev 137799)
+++ trunk/PKGBUILD	2011-09-11 10:02:16 UTC (rev 137800)
@@ -5,7 +5,7 @@
 pkgname=kdebase-workspace
 _pkgname=kde-workspace
 pkgver=4.7.1
-pkgrel=5
+pkgrel=7
 pkgdesc="KDE Base Workspace"
 arch=('i686' 'x86_64')
 url='http://www.kde.org'
@@ -30,7 +30,8 @@
 options=('emptydirs')
 source=("http://download.kde.org/stable/${pkgver}/src/${_pkgname}-${pkgver}.tar.bz2"
         'kdm-zsh-profile.patch' 'kdm' 'kde.pam' 'kde-np.pam' 'kscreensaver.pam'
-        'fixpath.patch' 'terminate-server.patch')
+        'fixpath.patch' 'terminate-server.patch'
+        'important-performance-bugfix.patch')
 sha1sums=('c7867d2f788086078abbcff53a035a6131232539'
           '8c2bdefb23a03b753b78d16944d03fa3939d2d99'
           '5db3a245201bd4a50e65aa2ef583cf5490e4f646'
@@ -38,7 +39,8 @@
           '603cc79c4d2b4eae62bb5f244aeecb3a778b5516'
           '106635aa1aae51d6f0668b1853f6c49a4fe9d3d8'
           'd7b5883f7e65c6839b1f65f94d58026673dd0226'
-          'ac7bc292c865bc1ab8c02e6341aa7aeaf1a3eeee')
+          'ac7bc292c865bc1ab8c02e6341aa7aeaf1a3eeee'
+          '4fa046db21e3203771fd29bc0e1c32918862b894')
 
 build() {
 	cd "${srcdir}"/${_pkgname}-${pkgver}
@@ -46,6 +48,9 @@
 	patch -p0 -i "${srcdir}"/fixpath.patch
 	patch -p0 -i "${srcdir}"/terminate-server.patch
 
+    # Already fixed upstream
+    patch -p1 -i "${srcdir}"/important-performance-bugfix.patch
+
 	cd "${srcdir}"
 	mkdir build
 	cd build

Added: trunk/important-performance-bugfix.patch
===================================================================
--- trunk/important-performance-bugfix.patch	                        (rev 0)
+++ trunk/important-performance-bugfix.patch	2011-09-11 10:02:16 UTC (rev 137800)
@@ -0,0 +1,91 @@
+commit e142a1a142cbc8b87f021223e6abc947f456a7f9
+Author: Thomas Lübking <thomas.luebking at gmail.com>
+Date:   Thu Sep 8 22:20:35 2011 +0200
+
+    replace non-const QVector::operator[] accesses with const ::at() to avoid maaany deep vecor copies
+
+diff --git a/kwin/effects.cpp b/kwin/effects.cpp
+index e0c76cb..f5863fc0 100644
+--- a/kwin/effects.cpp
++++ b/kwin/effects.cpp
+@@ -200,7 +200,7 @@ void EffectsHandlerImpl::reconfigure()
+ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->prePaintScreen(data, time);
++        loaded_effects.at(current_paint_screen++).second->prePaintScreen(data, time);
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -209,7 +209,7 @@ void EffectsHandlerImpl::prePaintScreen(ScreenPrePaintData& data, int time)
+ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData& data)
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->paintScreen(mask, region, data);
++        loaded_effects.at(current_paint_screen++).second->paintScreen(mask, region, data);
+         --current_paint_screen;
+     } else
+         scene->finalPaintScreen(mask, region, data);
+@@ -218,7 +218,7 @@ void EffectsHandlerImpl::paintScreen(int mask, QRegion region, ScreenPaintData&
+ void EffectsHandlerImpl::postPaintScreen()
+ {
+     if (current_paint_screen < loaded_effects.size()) {
+-        loaded_effects[current_paint_screen++].second->postPaintScreen();
++        loaded_effects.at(current_paint_screen++).second->postPaintScreen();
+         --current_paint_screen;
+     }
+     // no special final code
+@@ -227,7 +227,7 @@ void EffectsHandlerImpl::postPaintScreen()
+ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& data, int time)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->prePaintWindow(w, data, time);
++        loaded_effects.at(current_paint_window++).second->prePaintWindow(w, data, time);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -236,7 +236,7 @@ void EffectsHandlerImpl::prePaintWindow(EffectWindow* w, WindowPrePaintData& dat
+ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->paintWindow(w, mask, region, data);
++        loaded_effects.at(current_paint_window++).second->paintWindow(w, mask, region, data);
+         --current_paint_window;
+     } else
+         scene->finalPaintWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -245,7 +245,7 @@ void EffectsHandlerImpl::paintWindow(EffectWindow* w, int mask, QRegion region,
+ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, double opacity, double frameOpacity)
+ {
+     if (current_paint_effectframe < loaded_effects.size()) {
+-        loaded_effects[current_paint_effectframe++].second->paintEffectFrame(frame, region, opacity, frameOpacity);
++        loaded_effects.at(current_paint_effectframe++).second->paintEffectFrame(frame, region, opacity, frameOpacity);
+         --current_paint_effectframe;
+     } else {
+         const EffectFrameImpl* frameImpl = static_cast<const EffectFrameImpl*>(frame);
+@@ -256,7 +256,7 @@ void EffectsHandlerImpl::paintEffectFrame(EffectFrame* frame, QRegion region, do
+ void EffectsHandlerImpl::postPaintWindow(EffectWindow* w)
+ {
+     if (current_paint_window < loaded_effects.size()) {
+-        loaded_effects[current_paint_window++].second->postPaintWindow(w);
++        loaded_effects.at(current_paint_window++).second->postPaintWindow(w);
+         --current_paint_window;
+     }
+     // no special final code
+@@ -273,7 +273,7 @@ bool EffectsHandlerImpl::provides(Effect::Feature ef)
+ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data)
+ {
+     if (current_draw_window < loaded_effects.size()) {
+-        loaded_effects[current_draw_window++].second->drawWindow(w, mask, region, data);
++        loaded_effects.at(current_draw_window++).second->drawWindow(w, mask, region, data);
+         --current_draw_window;
+     } else
+         scene->finalDrawWindow(static_cast<EffectWindowImpl*>(w), mask, region, data);
+@@ -282,7 +282,7 @@ void EffectsHandlerImpl::drawWindow(EffectWindow* w, int mask, QRegion region, W
+ void EffectsHandlerImpl::buildQuads(EffectWindow* w, WindowQuadList& quadList)
+ {
+     if (current_build_quads < loaded_effects.size()) {
+-        loaded_effects[current_build_quads++].second->buildQuads(w, quadList);
++        loaded_effects.at(current_build_quads++).second->buildQuads(w, quadList);
+         --current_build_quads;
+     }
+ }




More information about the arch-commits mailing list