Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
534dcbe0
Commit
534dcbe0
authored
Feb 02, 2018
by
Sayed Adel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core:ppc Fix compile issue with Eigen
parent
f57630d9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
0 deletions
+25
-0
vsx_utils.hpp
modules/core/include/opencv2/core/vsx_utils.hpp
+25
-0
No files found.
modules/core/include/opencv2/core/vsx_utils.hpp
View file @
534dcbe0
...
...
@@ -47,6 +47,10 @@
#include "opencv2/core/cvdef.h"
#ifndef SKIP_INCLUDES
# include <assert.h>
#endif
//! @addtogroup core_utils_vsx
//! @{
#if CV_VSX
...
...
@@ -520,6 +524,27 @@ VSX_IMPL_CONV_EVEN_2_4(vec_float4, vec_udword2, vec_ctf, vec_ctfo)
VSX_IMPL_CONV_EVEN_2_4
(
vec_int4
,
vec_double2
,
vec_cts
,
vec_ctso
)
VSX_IMPL_CONV_EVEN_2_4
(
vec_uint4
,
vec_double2
,
vec_ctu
,
vec_ctuo
)
// Only for Eigen!
/*
* changing behavior of conversion intrinsics for gcc has effect on Eigen
* so we redfine old behavior again only on gcc, clang
*/
#if !defined(__clang__) || __clang_major__ > 4
// ignoring second arg since Eigen only truncates toward zero
# define VSX_IMPL_CONV_2VARIANT(rt, rg, fnm, fn2) \
VSX_FINLINE(rt) fnm(const rg& a, int only_truncate) \
{ \
assert(only_truncate == 0); \
(void)only_truncate; \
return fn2(a); \
}
VSX_IMPL_CONV_2VARIANT
(
vec_int4
,
vec_float4
,
vec_cts
,
vec_cts
)
VSX_IMPL_CONV_2VARIANT
(
vec_float4
,
vec_int4
,
vec_ctf
,
vec_ctf
)
// define vec_cts for converting double precision to signed doubleword
// which isn't combitable with xlc but its okay since Eigen only use it for gcc
VSX_IMPL_CONV_2VARIANT
(
vec_dword2
,
vec_double2
,
vec_cts
,
vec_ctsl
)
#endif // Eigen
#endif // Common GCC, CLANG compatibility
/*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment