Repository navigation
Fix ARMV9SME kernel selection in CMake cross builds - #6114
Open
Kiptoo-Deus wants to merge 1 commit into
Open
Kiptoo-Deus wants to merge 1 commit into
Kiptoo-Deus wants to merge 1 commit into
Conversation
This branch has not been deployed
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.
Follow-up to #5978 (for #5976).
#5978 added
ARMV9SMEto theARMV8SVEblock incmake/prebuild.cmake, butARMV9SMEis also listed earlier in the sameif/elseifchain, in theNEOVERSEN2block. That block is matched first, soARMV9SMEstill getsSGEMM_UNROLL_N/DGEMM_UNROLL_Nof 4.KERNEL.ARMV9SMEincludesKERNEL.ARMV8SVE, which uses the 2x8/1x8 SVE kernels, so the build looks for files likesgemm_kernel_sve_v2x4.Sthat don't exist.This removes
ARMV9SMEfrom theNEOVERSEN2block so it reaches theARMV8SVEblock as intended.This only affects the CMake path that writes the config without running getarch, i.e. cross builds. Native builds get the values from getarch.
Tested on macOS (Apple M, AppleClang 21) by cross-configuring develop with
-DCMAKE_SYSTEM_NAME=Darwin -DCMAKE_SYSTEM_PROCESSOR=arm64 -DTARGET=ARMV8 -DDYNAMIC_ARCH=ON -DNOFORTRAN=ON:fatal error: '.../kernel/arm64/sgemm_kernel_sve_v2x4.S' file not found(andsgemm_kernel_inter_sve_v2x4.S)ARMV9SMEkernels are inlibopenblas.a, and ctest passes (14/14)Unrelated, but I hit it while testing: with the Ninja generator on macOS,
libopenblas.aon develop ends up containing onlyxerbla.c.o. InCMakeLists.txtthe Ninja-specificCREATE_STATIC_LIBRARY_COMMANDis set and then overwritten right after theif/elseby theobjects*.rspversion, which Ninja doesn't generate. I used the Makefiles generator for the test above. Happy to open a separate PR for that if useful.