Fix check for .cfi_negate_ra_state on aarch64#18262
Merged
behlendorf merged 1 commit intoopenzfs:masterfrom Mar 6, 2026
Merged
Fix check for .cfi_negate_ra_state on aarch64#18262behlendorf merged 1 commit intoopenzfs:masterfrom
behlendorf merged 1 commit intoopenzfs:masterfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This pull request improves the reliability of detecting assembler support for the .cfi_negate_ra_state CFI directive on AArch64 platforms by replacing an unreliable preprocessor check with proper autoconf feature detection.
Changes:
- Replaces
LD_VERSIONpreprocessor check with autoconf-basedHAVE_AS_CFI_PSEUDO_OPmacro - Adds new autoconf macro
ZFS_AC_CONFIG_ALWAYS_TOOLCHAIN_CFI_PSEUDO_OPto detect assembler support at configure time - Updates comments in assembly files to better describe the feature check
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| module/icp/asm-aarch64/blake3/b3_aarch64_sse41.S | Replaces LD_VERSION check with HAVE_AS_CFI_PSEUDO_OP macro and updates comment |
| module/icp/asm-aarch64/blake3/b3_aarch64_sse2.S | Replaces LD_VERSION check with HAVE_AS_CFI_PSEUDO_OP macro and updates comment |
| config/zfs-build.m4 | Integrates new CFI pseudo-op detection macro into configure flow |
| config/toolchain-simd.m4 | Adds ZFS_AC_CONFIG_ALWAYS_TOOLCHAIN_CFI_PSEUDO_OP macro for detecting .cfi_negate_ra_state support |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
behlendorf
reviewed
Mar 2, 2026
Contributor
Contributor
|
Not directly related to this, but in the same sort of arena, we had to do this recently: |
Contributor
|
Oh interesting. Thanks for the heads up on those related CFI changes, even if they're at the moment a macOS thing. |
Checking for LD_VERSION in unreliable as not all distros define it on the compiler's preprocessor. Explicitly check it via autoconf. This fixes support for Ubuntu 18.04 on arm64. Signed-off-by: Juhyung Park <qkrwngud825@gmail.com>
Contributor
Author
|
Rebased to master with feedback applied. |
behlendorf
approved these changes
Mar 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checking for LD_VERSION in unreliable as not all distros define it on the compiler's preprocessor.
Explicitly check it via autoconf.
This fixes support for Ubuntu 18.04 on arm64.
Motivation and Context
Previous compatibility fix 90ba19e is incomplete as not all distros define LD_VERSION.
Since the linker version is unavailable in preprocessor, the only reliable method is to detect it and control via macro as a compiler flag.
This fixes Ubuntu 18.04 compatibility on arm64.
Description
Removes unreliable LD_VERSION check and introduced a HAVE_AS_CFI_PSEUDO_OP flag on autoconf.
How Has This Been Tested?
Passes build on Ubuntu 18.04 - 26.04, armhf/arm64/amd64.
Types of changes
Checklist:
Signed-off-by.