[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#786345: marked as done (pixman: enable vmx for ppc64el)



Your message dated Sat, 12 Sep 2015 11:19:10 +0000
with message-id <E1Zaipq-0007FT-0H@franck.debian.org>
and subject line Bug#786345: fixed in pixman 0.33.2-1
has caused the Debian Bug report #786345,
regarding pixman: enable vmx for ppc64el
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
786345: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=786345
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Source: pixman
Version: 0.32.6-3
Severity: normal
Tags: patch
User: debian-powerpc@lists.debian.org

Dear Maintainer,

The package pixman had the usage of vmx disabled for ppc64el arch, because it
had tests failing when it was enabled.
That happened due to some differences on how data is treated from big to little
endian.

I am attaching a patch that re-enables vmx and includes some work arounds for
cases that have endianness conflicts.

I tested the patch on ppc64le and powerpc vms.

If you have questions or suggestions, please let me know.

Regards.
Fernando

-- System Information:
Debian Release: 8.0
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'unstable'), (500, 'stable')
Architecture: ppc64el (ppc64le)

Kernel: Linux 3.16.0-4-powerpc64le (SMP w/16 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -u pixman-0.32.6/debian/changelog pixman-0.32.6/debian/changelog
--- pixman-0.32.6/debian/changelog
+++ pixman-0.32.6/debian/changelog
@@ -1,3 +1,10 @@
+pixman (0.32.6-3ppc64el1) UNRELEASED; urgency=medium
+
+  * Reenabled vmx for ppc64el and provided some workarounds so vmx works for
+    both endiannesses. 
+
+ -- Fernando Seiti Furusato <ferseiti@br.ibm.com>  Wed, 20 May 2015 15:21:10 -0400
+
 pixman (0.32.6-3) sid; urgency=medium
 
   [ intrigeri ]
diff -u pixman-0.32.6/debian/patches/series pixman-0.32.6/debian/patches/series
--- pixman-0.32.6/debian/patches/series
+++ pixman-0.32.6/debian/patches/series
@@ -1,2 +1,3 @@
-ppc64el.diff
+#ppc64el.diff
 test-increase-timeout.diff
+vmx-le.patch
only in patch2:
unchanged:
--- pixman-0.32.6.orig/debian/patches/vmx-le.patch
+++ pixman-0.32.6/debian/patches/vmx-le.patch
@@ -0,0 +1,126 @@
+--- a/pixman/pixman-vmx.c
++++ b/pixman/pixman-vmx.c
+@@ -34,13 +34,25 @@
+ 
+ #define AVV(x...) {x}
+ 
++#ifndef __LITTLE_ENDIAN__
++#define MERGEH(a,b) vec_mergeh(a,b)
++#define MERGEL(a,b) vec_mergel(a,b)
++#define SPLAT_VEC AVV(						\
++		0x00, 0x00, 0x00, 0x00, 0x04, 0x04, 0x04, 0x04,	\
++		0x08, 0x08, 0x08, 0x08, 0x0C, 0x0C, 0x0C, 0x0C)
++#else
++#define MERGEH(a,b) vec_mergeh(b,a)
++#define MERGEL(a,b) vec_mergel(b,a)
++#define SPLAT_VEC AVV(             				\
++		0x03, 0x03, 0x03, 0x03, 0x07, 0x07, 0x07, 0x07,	\
++		0x0B, 0x0B, 0x0B, 0x0B, 0x0F, 0x0F, 0x0F, 0x0F)
++#endif
++
+ static force_inline vector unsigned int
+ splat_alpha (vector unsigned int pix)
+ {
+     return vec_perm (pix, pix,
+-		     (vector unsigned char)AVV (
+-			 0x00, 0x00, 0x00, 0x00, 0x04, 0x04, 0x04, 0x04,
+-			 0x08, 0x08, 0x08, 0x08, 0x0C, 0x0C, 0x0C, 0x0C));
++		     (vector unsigned char)SPLAT_VEC);
+ }
+ 
+ static force_inline vector unsigned int
+@@ -50,11 +62,11 @@
+ 
+     /* unpack to short */
+     hi = (vector unsigned short)
+-	vec_mergeh ((vector unsigned char)AVV (0),
++	MERGEH ((vector unsigned char)AVV (0),
+ 		    (vector unsigned char)p);
+ 
+     mod = (vector unsigned short)
+-	vec_mergeh ((vector unsigned char)AVV (0),
++	MERGEH ((vector unsigned char)AVV (0),
+ 		    (vector unsigned char)a);
+ 
+     hi = vec_mladd (hi, mod, (vector unsigned short)
+@@ -67,10 +79,10 @@
+ 
+     /* unpack to short */
+     lo = (vector unsigned short)
+-	vec_mergel ((vector unsigned char)AVV (0),
++	MERGEL ((vector unsigned char)AVV (0),
+ 		    (vector unsigned char)p);
+     mod = (vector unsigned short)
+-	vec_mergel ((vector unsigned char)AVV (0),
++	MERGEL ((vector unsigned char)AVV (0),
+ 		    (vector unsigned char)a);
+ 
+     lo = vec_mladd (lo, mod, (vector unsigned short)
+@@ -125,25 +137,35 @@
+ }
+ 
+ /* in == pix_multiply */
++#ifndef __LITTLE_ENDIAN__
++#define MASK_SHIFT(pointer) vec_lvsl(0,pointer)
++#else
++#define MASK_SHIFT(pointer)							\
++    vec_xor(*((typeof(pointer ## _mask)*)pointer),			\
++	     (typeof(pointer ## _mask))AVV(				\
++		0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 	\
++		0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03))
++#endif
++
+ #define in_over(src, srca, mask, dest)					\
+     over (pix_multiply (src, mask),					\
+           pix_multiply (srca, mask), dest)
+ 
+-
+ #define COMPUTE_SHIFT_MASK(source)					\
+-    source ## _mask = vec_lvsl (0, source);
++    source ## _mask = MASK_SHIFT(source);
+ 
+ #define COMPUTE_SHIFT_MASKS(dest, source)				\
+-    source ## _mask = vec_lvsl (0, source);
++    source ## _mask = MASK_SHIFT(source);
+ 
+ #define COMPUTE_SHIFT_MASKC(dest, source, mask)				\
+-    mask ## _mask = vec_lvsl (0, mask);					\
+-    source ## _mask = vec_lvsl (0, source);
++    mask ## _mask = MASK_SHIFT(mask);					\
++    source ## _mask = MASK_SHIFT(source);
+ 
+ /* notice you have to declare temp vars...
+  * Note: tmp3 and tmp4 must remain untouched!
+  */
+ 
++#ifndef __LITTLE_ENDIAN__
+ #define LOAD_VECTORS(dest, source)			  \
+     tmp1 = (typeof(tmp1))vec_ld (0, source);		  \
+     tmp2 = (typeof(tmp2))vec_ld (15, source);		  \
+@@ -162,11 +184,22 @@
+     v ## mask = (typeof(v ## mask))			  \
+ 	vec_perm (tmp1, tmp2, mask ## _mask);
+ 
+-#define LOAD_VECTORSM(dest, source, mask)				\
+-    LOAD_VECTORSC (dest, source, mask)					\
+-    v ## source = pix_multiply (v ## source,				\
++#else
++#define LOAD_VECTORS(dest, source)                        \
++    v ## source = *((typeof(v ## source)*)source);        \
++    v ## dest = *((typeof(v ## dest)*)dest);
++
++#define LOAD_VECTORSC(dest, source, mask)                 \
++    v ## source = *((typeof(v ## source)*)source);        \
++    v ## dest = *((typeof(v ## dest)*)dest);              \
++    v ## mask = *((typeof(v ## mask)*)mask);
++
++#endif
++
++#define LOAD_VECTORSM(dest, source, mask)                               \
++    LOAD_VECTORSC (dest, source, mask)                                  \
++    v ## source = pix_multiply (v ## source,                            \
+                                 splat_alpha (v ## mask));
+-
+ #define STORE_VECTOR(dest)						\
+     vec_st ((vector unsigned int) v ## dest, 0, dest);
+ 

--- End Message ---
--- Begin Message ---
Source: pixman
Source-Version: 0.33.2-1

We believe that the bug you reported is fixed in the latest version of
pixman, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 786345@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Julien Cristau <jcristau@debian.org> (supplier of updated pixman package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sat, 12 Sep 2015 13:08:02 +0200
Source: pixman
Binary: libpixman-1-0 libpixman-1-0-udeb libpixman-1-0-dbg libpixman-1-dev
Architecture: source
Version: 0.33.2-1
Distribution: sid
Urgency: medium
Maintainer: Debian X Strike Force <debian-x@lists.debian.org>
Changed-By: Julien Cristau <jcristau@debian.org>
Description:
 libpixman-1-0 - pixel-manipulation library for X and cairo
 libpixman-1-0-dbg - pixel-manipulation library for X and cairo (debugging symbols)
 libpixman-1-0-udeb - pixel-manipulation library for X and cairo (udeb)
 libpixman-1-dev - pixel-manipulation library for X and cairo (development files)
Closes: 760100 786345
Changes:
 pixman (0.33.2-1) sid; urgency=medium
 .
   [ Andreas Boll ]
   * New upstream release candidate.
   * Enable vmx on ppc64el (closes: #786345).
   * Update Vcs-* fields.
   * Add upstream url.
   * Drop XC- prefix from Package-Type field.
   * Bump standards version to 3.9.6.
 .
   [ intrigeri ]
   * Simplify hardening build flags handling (closes: #760100).
     Thanks to Simon Ruderich <simon@ruderich.org> for the patch.
   * Enable all hardening build flags. Thanks to Simon Ruderich too.
Checksums-Sha1:
 5a170e2977e7ea225ae6a53e3874a8475f43289c 2050 pixman_0.33.2-1.dsc
 fa093856557737d0a2e570261bae0f3ae9bc6b45 846982 pixman_0.33.2.orig.tar.gz
 f784f9be2f4c3c5db6987aea187eebb79dfa50ad 305928 pixman_0.33.2-1.diff.gz
Checksums-Sha256:
 d79b492f52da8d6f9bf3b7432839f2d9fd6fc6894b7985f62e7179a901062609 2050 pixman_0.33.2-1.dsc
 fcd593cc841ae7a060814b8b7335be5c5e378b8fbda5054bc423c29993e16007 846982 pixman_0.33.2.orig.tar.gz
 0d9df8c05ef55a55beb90935b5266902c3980c0da42a8d1271b1928cf5a47fc7 305928 pixman_0.33.2-1.diff.gz
Files:
 04119a9657e4a55da86a9795e5cd6491 2050 devel optional pixman_0.33.2-1.dsc
 fdf5211a551ce1a6737bdf9049019df3 846982 devel optional pixman_0.33.2.orig.tar.gz
 cd48a122de9f3a09ef50f1f41c2050fc 305928 devel optional pixman_0.33.2-1.diff.gz

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJV9AfOAAoJEDEBgAUJBeQMMmgQAMPPvsodjhPAkQzWd7Hu4qpu
Jthc3Ucc5m4G2qYH8a0FrSogZUgTjGT0Q5oSe5bGJEzdhXYqj+PGYIqEu4fDb5YN
6MQ3I/frnZKdL3HLdOlhTrgy0P9cyBQI5kwJEmHmgPfY2SWX5VhNFbEXORzzWw51
CcS2R0m3bzFANyFnb1YAopggwvsItkDATef55p2xlFJ3jM5Njxq25C9FTSv45rJQ
5o8ZS3FmVumywNOppS/2LB/sDDc1AeP/+2Q2R+8i8z544OWMQn/Ez4/zFX25uEY5
U4CGxvDXDEgHf2j+OexzsmdQXlZJuWeyI8ylpSqlTuJOhFvjFNblowBVYu2iNG9e
cvFCO8VM24YPV2P2/vuZ5BAmWU5EfvKPKcRXXVrzWbxGHokyUmmEqWu+2r2Ydbo2
xehYjJc1h72uGQ9Myl5nD87lvzvAu5kgMf8xqZAAGHqBfIDi57lUOGUhjyyFFOY7
/HX1hUiBFNVYbmg60f6zhl6PhC/6ivJ1+46pv1qP9ADmex5D88dc+KhFSkj8Uw/z
la9ucJOx8mDWceuzkqr9i+mSKQP8UDoa/H3AmhliSJFxmv6nd1NNcyXJLm2JLFd/
r66l6UDHKlBPPrrXBa1DXhKiRJcVQm34kYhn1oaU71OJf2lQhRIpvW+1ex274djB
mW4mEWRx642IS+n05aTW
=I7Od
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: