[opencv] 08/251: core(stat): register dispatched code, fix build

Nobuhiro Iwamatsu iwamatsu at moszumanska.debian.org
Sun Aug 27 23:27:17 UTC 2017


This is an automated email from the git hooks/post-receive script.

iwamatsu pushed a commit to annotated tag 3.3.0
in repository opencv.

commit c45d3568ae81d63ba0280122e6d5c7dde65fd323
Author: Alexander Alekhin <alexander.a.alekhin at gmail.com>
Date:   Sun Jul 2 13:23:13 2017 +0000

    core(stat): register dispatched code, fix build
---
 modules/core/CMakeLists.txt    | 1 +
 modules/core/src/stat.cpp      | 2 +-
 modules/core/src/stat.simd.hpp | 3 +++
 3 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/modules/core/CMakeLists.txt b/modules/core/CMakeLists.txt
index 6de15ba..9793e71 100644
--- a/modules/core/CMakeLists.txt
+++ b/modules/core/CMakeLists.txt
@@ -1,6 +1,7 @@
 set(the_description "The Core Functionality")
 
 ocv_add_dispatched_file(mathfuncs_core SSE2 AVX AVX2)
+ocv_add_dispatched_file(stat SSE4_2 AVX AVX2)
 
 ocv_add_module(core
                "${OPENCV_HAL_LINKER_LIBS}"
diff --git a/modules/core/src/stat.cpp b/modules/core/src/stat.cpp
index fd6e0a2..b802d0a 100644
--- a/modules/core/src/stat.cpp
+++ b/modules/core/src/stat.cpp
@@ -4233,7 +4233,7 @@ cvNorm( const void* imgA, const void* imgB, int normType, const void* maskarr )
 
 namespace cv { namespace hal {
 
-static const uchar popCountTable[] =
+extern const uchar popCountTable[256] =
 {
     0, 1, 1, 2, 1, 2, 2, 3, 1, 2, 2, 3, 2, 3, 3, 4, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5,
     1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6,
diff --git a/modules/core/src/stat.simd.hpp b/modules/core/src/stat.simd.hpp
index 206817c..4386773 100644
--- a/modules/core/src/stat.simd.hpp
+++ b/modules/core/src/stat.simd.hpp
@@ -5,6 +5,9 @@
 #include "opencv2/core/hal/intrin.hpp"
 
 namespace cv { namespace hal {
+
+extern const uchar popCountTable[256];
+
 CV_CPU_OPTIMIZATION_NAMESPACE_BEGIN
 
 // forward declarations

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/opencv.git



More information about the debian-science-commits mailing list