Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📚 Backward incompatibility: we are no longer bulding with -march=native, please README #126

Closed
klaxalk opened this issue Dec 9, 2021 · 0 comments
Assignees
Labels
users-read-me information to users about a backwards-incompatible change

Comments

@klaxalk
Copy link
Member

klaxalk commented Dec 9, 2021

This is an important notice for everyone using our system. Up until now, we have had our build profiles in catkin workspaces set up with additional flags for compiling with -march=native. We used this for years, so most of you probably have this set automatically. The original motivation was to speed up our software since this flag allows the compiler to optimize the code for each particular architecture of the CPU.

Recently, we conducted a series of rigorous tests that show, that overall, the runtime benefits of this are negligible at best and negative on average. Moreover, using this flag significantly complicates dynamic linking with libraries up to a point, where using nodelets can lead to incompatibility with other pre-installed software. And those incompatibilities show up non-deterministically, are difficult to debug, and impractical to solve.

Therefore, we decided to drop the flag from all our workspaces, such that runtime compatibility with all pre-installed software is maintained. What does it mean for you?

  • Re-running our automated scripts and installers can cause compilation issues on pre-existing installations. The install scripts will update the flags within the mrs_workspace, which will then refuse to compile. Complete cleanup of the workspace is needed.
  • Users of PCL and PCL-related software, beware. We used to compile our own PCL with -march=native. Some of our software still checks for the environment variable PCL_CROSS_COMPILATION. Set this variable to false, or remove it completely from your shell's RC file.
  • Our catkin init alias will no longer set build profiles with --march=native. Therefore, any newly-created workspace might be incompatible with your old workspaces, unless you update and clean your workspaces.
  • We strongly recommend following our How to manage Catkin workspaces guide. Please, use it to verify the state, configuration, and mutual dependencies of your workspaces. We recommend cleaning and recompiling everything without -march=native to prevent future compatibility issues.
@klaxalk klaxalk added documentation Improvements or additions to documentation users-read-me information to users about a backwards-incompatible change and removed documentation Improvements or additions to documentation labels Dec 9, 2021
@klaxalk klaxalk self-assigned this Dec 9, 2021
@klaxalk klaxalk closed this as completed Nov 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
users-read-me information to users about a backwards-incompatible change
Projects
None yet
Development

No branches or pull requests

1 participant