[Bug 242147] multimedia/ffmpeg: Illegal instruction on i586
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Mon Nov 25 23:57:21 UTC 2019
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=242147
Jan Beich <jbeich at FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Blocks| |210505
Keywords| |regression
--- Comment #4 from Jan Beich <jbeich at FreeBSD.org> ---
Likely a regression from options refactor in graphics/opencv which makes i386
use -msse -msse2 -mfpmath=sse on all files. For runtime detection to work only
functions (or files) that use SSE2 instructions should be built with -msse2,
letting the caller check CPU features and decide whether to use optimized
functions. If the caller is built with -msse2 you get a crash on pre-SSE2
hardware. Unfortunately, upstream checks SSE2 support at compile time.
https://github.com/opencv/opencv/search?q=checkHardwareSupport
https://github.com/opencv/opencv/blob/3.4.1/cmake/OpenCVCompilerOptimizations.cmake#L71
While the following may help
# OpenCV minimum SIMD without runtime detection
CMAKE_ARGS+= ${CMAKE_ARGS_${ARCH}}
CMAKE_ARGS_amd64=-DCPU_BASELINE_DISABLE:STRING=SSE3
CMAKE_ARGS_i386=-DCPU_BASELINE_DISABLE:STRING=SSE
it breaks building SIMD-optimized code
FAILED: modules/core/CMakeFiles/opencv_core.dir/mathfuncs_core.avx.cpp.o
/usr/bin/c++ -DCVAPI_EXPORTS -D_USE_MATH_DEFINES -D__OPENCV_BUILD=1
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-DCV_CPU_COMPILE_AVX=1 -DCV_CPU_COMPILE_POPCNT=1 -DCV_CPU_COMPILE_SSE2=1
-DCV_CPU_COMPILE_SSE3=1 -DCV_CPU_COMPILE_SSE4_1=1 -DCV_CPU_COMPILE_SSE4_2=1
-DCV_CPU_COMPILE_SSE=1 -DCV_CPU_COMPILE_SSSE3=1 -DCV_CPU_DISPATCH_MODE=AVX
-I/wrkdirs/usr/ports/graphics/opencv-core/work/opencv-3.4.1/modules/core/include
-I/wrkdirs/usr/ports/graphics/opencv-core/work/opencv-3.4.1/modules/core/src
-Imodules/core -isystem . -isystem /usr/local/include/eigen3 -O2 -pipe
-fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing
-isystem /usr/local/include -std=c++11 -fsigned-char -W -Wall
-Werror=return-type -Werror=non-virtual-dtor -Werror=address
-Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations
-Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith
-Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wno-narrowing
-Wno-delete-non-virtual-dtor -Wno-unnamed-type-template-args -Wno-comment
-Wno-implicit-fallthrough -fdiagnostics-show-option -pthread -Qunused-arguments
-fomit-frame-pointer -ffunction-sections -fdata-sections -mfpmath=387
-fvisibility=hidden -fvisibility-inlines-hidden -O2 -pipe
-fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing
-isystem /usr/local/include -std=c++11 -DNDEBUG -fPIC -std=c++11 -msse
-msse2 -msse3 -mssse3 -msse4.1 -mpopcnt -msse4.2 -mavx -MD -MT
modules/core/CMakeFiles/opencv_core.dir/mathfuncs_core.avx.cpp.o -MF
modules/core/CMakeFiles/opencv_core.dir/mathfuncs_core.avx.cpp.o.d -o
modules/core/CMakeFiles/opencv_core.dir/mathfuncs_core.avx.cpp.o -c
modules/core/mathfuncs_core.avx.cpp
error: the '387' unit is not supported with this instruction set
Referenced Bugs:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=210505
[Bug 210505] [exp-run] graphics/opencv: Update to 3.4.1
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-multimedia
mailing list