[mutter] meta-actor-window: Use G_UNLIKELY for TFP check
- From: Adel Gadllah <agadllah src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] meta-actor-window: Use G_UNLIKELY for TFP check
- Date: Thu, 18 Nov 2010 17:51:56 +0000 (UTC)
commit 64c37852b17b2be4e801257b1eda4a1f950eae54
Author: Adel Gadllah <adel gadllah gmail com>
Date: Sat Oct 23 22:31:37 2010 +0200
meta-actor-window: Use G_UNLIKELY for TFP check
This is just a microptimization, as we pretty much always use
TFP (and do the check every time we set a pixmap),
we can let gcc generate better code here.
https://bugzilla.gnome.org/show_bug.cgi?id=633002
src/compositor/meta-window-actor.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/compositor/meta-window-actor.c b/src/compositor/meta-window-actor.c
index f08f043..c737d6d 100644
--- a/src/compositor/meta-window-actor.c
+++ b/src/compositor/meta-window-actor.c
@@ -1821,8 +1821,8 @@ check_needs_pixmap (MetaWindowActor *self)
* do it here.
* See: http://bugzilla.clutter-project.org/show_bug.cgi?id=2236
*/
- if (!clutter_glx_texture_pixmap_using_extension (
- CLUTTER_GLX_TEXTURE_PIXMAP (priv->actor)))
+ if (G_UNLIKELY (!clutter_glx_texture_pixmap_using_extension (
+ CLUTTER_GLX_TEXTURE_PIXMAP (priv->actor))))
g_warning ("NOTE: Not using GLX TFP!\n");
g_object_get (priv->actor,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]