pkgsrc-WIP-changes archive

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

plink: Support non-x86 via SIMDE



Module Name:	pkgsrc-wip
Committed By:	Jason Bacon <bacon%NetBSD.org@localhost>
Pushed By:	outpaddling
Date:		Mon Dec 25 08:12:31 2023 -0600
Changeset:	c65a0588bf6f799966dced7d17801e185598624f

Modified Files:
	plink/Makefile
	plink/distinfo
Added Files:
	plink/patches/patch-SFMT.h
	plink/patches/patch-plink__common.h

Log Message:
plink: Support non-x86 via SIMDE

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=c65a0588bf6f799966dced7d17801e185598624f

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 plink/Makefile                      |  1 +
 plink/distinfo                      |  2 ++
 plink/patches/patch-SFMT.h          | 18 ++++++++++++++++++
 plink/patches/patch-plink__common.h | 24 ++++++++++++++++++++++++
 4 files changed, 45 insertions(+)

diffs:
diff --git a/plink/Makefile b/plink/Makefile
index 16c3c47cfd..47e0d52612 100644
--- a/plink/Makefile
+++ b/plink/Makefile
@@ -43,5 +43,6 @@ do-install:
 
 .include "../../mk/blas.buildlink3.mk"
 .include "../../devel/zlib/buildlink3.mk"
+.include "../../devel/simde/buildlink3.mk"
 .include "../../mk/pthread.buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff --git a/plink/distinfo b/plink/distinfo
index c40cd7b3f5..362c7a30c5 100644
--- a/plink/distinfo
+++ b/plink/distinfo
@@ -3,3 +3,5 @@ $NetBSD$
 BLAKE2s (plink-1.9b6.17-79b2df8cffce480148b7d2197e4981bfeff3a3c0.tar.gz) = 3c4201041b1dddd25cdb8460f92168b867383412a86d8d57fb04f0feeb42a94d
 SHA512 (plink-1.9b6.17-79b2df8cffce480148b7d2197e4981bfeff3a3c0.tar.gz) = c80092a40cdef65099a7d9cf673ce155b74b8233d4eb6496130d83e0d846d0e85656f0389fb083226393f80a0f31ca91bd3c8eae47dcc2fd4e897e5f80b523a6
 Size (plink-1.9b6.17-79b2df8cffce480148b7d2197e4981bfeff3a3c0.tar.gz) = 3015223 bytes
+SHA1 (patch-SFMT.h) = 9972b59e863381af40e82de76aafeaebdb80a039
+SHA1 (patch-plink__common.h) = 679a8e9c91016d4920e443c625b2833b01c248d6
diff --git a/plink/patches/patch-SFMT.h b/plink/patches/patch-SFMT.h
new file mode 100644
index 0000000000..556370af2b
--- /dev/null
+++ b/plink/patches/patch-SFMT.h
@@ -0,0 +1,18 @@
+$NetBSD$
+
+# Support non-x86
+
+--- SFMT.h.orig	2023-12-25 14:05:59.079320161 +0000
++++ SFMT.h
+@@ -129,7 +129,10 @@ extern "C" {
+   128-bit SIMD like data type for standard C
+   ------------------------------------------*/
+ #ifdef __LP64__
+-  #include <emmintrin.h>
++  // #include <emmintrin.h>
++  #define SIMDE_ENABLE_NATIVE_ALIASES
++  #include <simde/x86/sse2.h>
++
+ 
+ /** 128-bit data structure */
+ union W128_T {
diff --git a/plink/patches/patch-plink__common.h b/plink/patches/patch-plink__common.h
new file mode 100644
index 0000000000..382ea04af6
--- /dev/null
+++ b/plink/patches/patch-plink__common.h
@@ -0,0 +1,24 @@
+$NetBSD$
+
+# Support non-x86
+
+--- plink_common.h.orig	2023-12-25 14:02:07.377466789 +0000
++++ plink_common.h
+@@ -187,14 +187,9 @@
+ // http://esr.ibiblio.org/?p=5095 ).
+ 
+ #ifdef __LP64__
+-  #ifndef __SSE2__
+-    // It's obviously possible to support this by writing 64-bit non-SSE2 code
+-    // shadowing each SSE2 intrinsic, but this almost certainly isn't worth the
+-    // development/testing effort until regular PLINK 2.0 development is
+-    // complete.  No researcher has ever asked me for this feature.
+-    #error "64-bit builds currently require SSE2.  Try producing a 32-bit build instead."
+-  #endif
+-  #include <emmintrin.h>
++// #include <emmintrin.h>
++  #define SIMDE_ENABLE_NATIVE_ALIASES
++  #include <simde/x86/sse2.h>
+ 
+   #define VECFTYPE __m128
+   #define VECITYPE __m128i


Home | Main Index | Thread Index | Old Index