-
Notifications
You must be signed in to change notification settings - Fork 446
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
Add support for elf_aux_info() on OpenBSD #1834
Conversation
It appears that |
83ec467
to
9ff08a3
Compare
Something like this is what I use most elsewhere. |
Using I guess this is to support non-configure build environments (but personally I think having two build configurations just leads to more problems than it solves and weird code like this where we have a mixture of ways of detecting things). If that is the logic, then we should be keeping all the existing system ifdefs and adding the Edit: I am aware we'd get some push-back if we forcibly went configure only from the people who just copy the entire code into their own source tree and build it themselves as part of their own project, but frankly I have minimal time for this behaviour. It leads to out-dated copies of code as it's not possible to upgrade trivially and is a disservice to their users. It's also an extra burden (assuming anyone notices) on distro builders. |
Well it would be better to have autoconf detect getauxval as well. I can do so. |
We previously discussed this in samtools/htscodecs#63 but punted on detecting during configure instead. It's easier here in htslib because the htscodecs build system vs htslib build system issue (mentioned in samtools/htscodecs#63 (comment)) does not arise. But it would be unfortunate for people doing non-configure builds if SIMD were now deactivated for them. Personally from reading the tea leaves of the maintainers' activity, I would have guessed that now is not the time for this sort of change… 😄 |
I made another PR. |
If it was considered sufficiently important (for the benefit of bioinformatics tools users on future OpenBSD) to activate this Neon code on OpenBSD using a system call that does not exist on current OpenBSD deployments, the following would suffice: #if defined __linux__ || defined __FreeBSD__
#include <sys/auxv.h>
+#elif defined __OpenBSD__
+#include <sys/param.h>
+#if OpenBSD >= 202409
+#include <sys/auxv.h>
+#endif
#elif defined __APPLE__
…
-#elif defined __FreeBSD__ && defined __arm__ && defined HWCAP_NEON
+#elif (defined __FreeBSD__ || (defined __OpenBSD__ && OpenBSD >= 202409)) && defined __arm__ && defined HWCAP_NEON
… etc … while being a smaller change for HTSlib — one that, in particular, would not affect other platforms. If activating SIMD code on future OpenBSD installations is your goal, you should really focus on htscodecs, where activating SIMD implementations would make a larger difference to overall run time. |
Closing as replaced by #1835 |
No description provided.