From 1c5de7b05831b3d66821707276b71974a232f5c7 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20M=C3=BCller?= Date: Tue, 23 Sep 2008 07:45:51 -0400 Subject: [PATCH] Move _mm_empty() to correct place The "fbComposeSetupSSE2()" function is guarding most of its code depending on the capabilities of the CPU, but unfortunately the call to "_mm_empty()" is not part of this code path but executed unconditionally. This results in a "illegal instruction" crash on non-MMX / non-SSE capable CPUs caused by the the "emms" instruction (embedded in "_mm_empty()"). Fix bug 17729. --- pixman/pixman-sse2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pixman/pixman-sse2.c b/pixman/pixman-sse2.c index 0f36436..6890f5f 100644 --- a/pixman/pixman-sse2.c +++ b/pixman/pixman-sse2.c @@ -2357,11 +2357,11 @@ fbComposeSetupSSE2(void) pixman_composeFunctions.combineC[PIXMAN_OP_ADD] = sse2CombineAddC; pixman_composeFunctions.combineMaskU = sse2CombineMaskU; + + _mm_empty(); } initialized = TRUE; - - _mm_empty(); } -- 2.7.4