ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

We've confirmed that this is a problem with our OpenCV deb, and released a new version yesterday. Updating (sudo apt-get update; sudo apt-get dist-upgrade) should fix it.

We were building OpenCV with all the way up to SSE4.2. OpenCV has SSE-optimized code paths for many algorithms, and dispatches to the fastest available implementation using runtime CPUID detection. Unfortunately, as far as I can tell, gcc only gives us file-level granularity in choosing the instruction set. So gcc would also optimize generic C code to use SSE4 when possible, resulting in "Illegal instruction" for some random subset of the OpenCV API. Short of a significant (and ugly) refactoring of OpenCV, we apparently lack a safe way to generate debs taking full advantage of runtime CPUID detection.

The new deb comprises on SSE2 (not SSE3/4), which is pretty universal and allows OpenCV to use almost all of its optimized code paths.

We've confirmed that this is a problem with our OpenCV deb, and released a new version yesterday. Updating (sudo apt-get update; sudo apt-get dist-upgrade) should fix it.

We were building OpenCV with all the way up to SSE4.2. OpenCV has SSE-optimized code paths for many algorithms, and dispatches to the fastest available implementation using runtime CPUID detection. Unfortunately, as far as I can tell, gcc only gives us file-level granularity in choosing the instruction set. So gcc would also optimize generic C code to use SSE4 when possible, resulting in "Illegal instruction" for some random subset of the OpenCV API. Short of a significant (and ugly) refactoring of OpenCV, we apparently lack a safe way to generate debs taking full advantage of runtime CPUID detection.

The new deb comprises compromises on SSE2 (not SSE3/4), which is pretty universal and allows OpenCV to use almost all of its optimized code paths.