Re: [Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-12-15 Thread Brad
- Original message -
> Brad  writes:
> 
> > On Tuesday 14 December 2010 14:44:09 Søren Sandmann wrote:
> > > From: Brad Smith 
> > > 
> > > Bug 29331.
> > 
> > Why was this posted? It was already commited 4 months ago.
> 
> I mistakenly sent out a bunch of old patches.   Sorry about that.
> 
> 
> Soren

Ok. I figured it was something like that.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


Re: [Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-12-15 Thread Soeren Sandmann
Brad  writes:

> On Tuesday 14 December 2010 14:44:09 Søren Sandmann wrote:
> > From: Brad Smith 
> >
> > Bug 29331.
> 
> Why was this posted? It was already commited 4 months ago.

I mistakenly sent out a bunch of old patches.  Sorry about that.


Soren
___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


Re: [Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-12-14 Thread Brad
On Tuesday 14 December 2010 14:44:09 Søren Sandmann wrote:
> From: Brad Smith 
>
> Bug 29331.

Why was this posted? It was already commited 4 months ago.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


[Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-12-14 Thread Søren Sandmann
From: Brad Smith 

Bug 29331.
---
 pixman/pixman-cpu.c |   25 -
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/pixman/pixman-cpu.c b/pixman/pixman-cpu.c
index e96b140..1b31885 100644
--- a/pixman/pixman-cpu.c
+++ b/pixman/pixman-cpu.c
@@ -61,6 +61,29 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
+#elif defined (__OpenBSD__)
+#include 
+#include 
+#include 
+
+static pixman_bool_t
+pixman_have_vmx (void)
+{
+if (!initialized)
+{
+   int mib[2] = { CTL_MACHDEP, CPU_ALTIVEC };
+   size_t length = sizeof(have_vmx);
+   int error =
+   sysctl (&mib, 2, &have_vmx, &length, NULL, 0);
+
+   if (error)
+   have_vmx = FALSE;
+
+   initialized = TRUE;
+}
+return have_vmx;
+}
+
 #elif defined (__linux__)
 #include 
 #include 
@@ -123,7 +146,7 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
-#else /* !__APPLE__ && !__linux__ */
+#else /* !__APPLE__ && !__OpenBSD__ && !__linux__ */
 #include 
 #include 
 
-- 
1.6.0.6

___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


Re: [Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-08-02 Thread Soeren Sandmann
Brad  writes:

> On Saturday 31 July 2010 05:45:25 Søren Sandmann wrote:
> > From: Brad Smith 
> >
> > Bug 29331.
> 
> FYI, I updated the diff with the bug report.

The new patch is included below. 


As a general note, it's usually easier for everybody if people
generate patches with

git format-patch 

and then send the result to this mailing list, possibly using git
send-email. That way we get a changelog entry, and I don't have to
fish patches out of bugzilla.


Thanks,
Soren



>From bad3e0ca25165544f176899e042d17bf18ad7691 Mon Sep 17 00:00:00 2001
From: Brad Smith 
Date: Mon, 2 Aug 2010 13:37:49 -0400
Subject: [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

Bug 29331.
---
 pixman/pixman-cpu.c |   25 -
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/pixman/pixman-cpu.c b/pixman/pixman-cpu.c
index e96b140..e4fb1e4 100644
--- a/pixman/pixman-cpu.c
+++ b/pixman/pixman-cpu.c
@@ -61,6 +61,29 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
+#elif defined (__OpenBSD__)
+#include 
+#include 
+#include 
+
+static pixman_bool_t
+pixman_have_vmx (void)
+{
+if (!initialized)
+{
+   int mib[2] = { CTL_MACHDEP, CPU_ALTIVEC };
+   size_t length = sizeof(have_vmx);
+   int error =
+   sysctl (mib, 2, &have_vmx, &length, NULL, 0);
+
+   if (error != 0)
+   have_vmx = FALSE;
+
+   initialized = TRUE;
+}
+return have_vmx;
+}
+
 #elif defined (__linux__)
 #include 
 #include 
@@ -123,7 +146,7 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
-#else /* !__APPLE__ && !__linux__ */
+#else /* !__APPLE__ && !__OpenBSD__ && !__linux__ */
 #include 
 #include 
 
-- 
1.7.1.1
___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


Re: [Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-08-01 Thread Brad
On Saturday 31 July 2010 05:45:25 Søren Sandmann wrote:
> From: Brad Smith 
>
> Bug 29331.

FYI, I updated the diff with the bug report.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman


[Pixman] [PATCH] Add support for AltiVec detection for OpenBSD/PowerPC.

2010-07-31 Thread Søren Sandmann
From: Brad Smith 

Bug 29331.
---
 pixman/pixman-cpu.c |   25 -
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/pixman/pixman-cpu.c b/pixman/pixman-cpu.c
index e96b140..1b31885 100644
--- a/pixman/pixman-cpu.c
+++ b/pixman/pixman-cpu.c
@@ -61,6 +61,29 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
+#elif defined (__OpenBSD__)
+#include 
+#include 
+#include 
+
+static pixman_bool_t
+pixman_have_vmx (void)
+{
+if (!initialized)
+{
+   int mib[2] = { CTL_MACHDEP, CPU_ALTIVEC };
+   size_t length = sizeof(have_vmx);
+   int error =
+   sysctl (&mib, 2, &have_vmx, &length, NULL, 0);
+
+   if (error)
+   have_vmx = FALSE;
+
+   initialized = TRUE;
+}
+return have_vmx;
+}
+
 #elif defined (__linux__)
 #include 
 #include 
@@ -123,7 +146,7 @@ pixman_have_vmx (void)
 return have_vmx;
 }
 
-#else /* !__APPLE__ && !__linux__ */
+#else /* !__APPLE__ && !__OpenBSD__ && !__linux__ */
 #include 
 #include 
 
-- 
1.6.0.6

___
Pixman mailing list
Pixman@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pixman