svn commit: r561216 - head/science/dlib-cpp/files

Piotr Kubaj pkubaj at FreeBSD.org
Mon Jan 11 14:07:59 UTC 2021


Author: pkubaj
Date: Mon Jan 11 14:07:58 2021
New Revision: 561216
URL: https://svnweb.freebsd.org/changeset/ports/561216

Log:
  science/dlib-cpp: fix build on powerpc64le
  
  clang doesn't implement vec_rsqrt.

Added:
  head/science/dlib-cpp/files/
  head/science/dlib-cpp/files/patch-dlib_simd_simd4f.h   (contents, props changed)

Added: head/science/dlib-cpp/files/patch-dlib_simd_simd4f.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/science/dlib-cpp/files/patch-dlib_simd_simd4f.h	Mon Jan 11 14:07:58 2021	(r561216)
@@ -0,0 +1,14 @@
+--- dlib/simd/simd4f.h.orig	2021-01-11 12:18:36 UTC
++++ dlib/simd/simd4f.h
+@@ -524,6 +524,11 @@ namespace dlib
+ 
+ // ----------------------------------------------------------------------------------------
+ 
++#if defined(DLIB_HAVE_VSX) && !defined(vec_rsqrt)
++extern inline __vector float __attribute__((always_inline)) vec_rsqrt(const __vector float& a)
++	{ return vec_div((__vector float){1, 1, 1, 1}, vec_sqrt(a)); }
++#endif
++
+     inline simd4f reciprocal_sqrt (const simd4f& item)
+     {
+ #ifdef DLIB_HAVE_SSE2


More information about the svn-ports-all mailing list