You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Without XSIMD_INLINE, in debug mode, two inline symbols were created and the linker picked
one (the one with -msve-vector-length=16) and applied it everywhere.
What changed:
xsimd_inline.hpp was renamed xsimd_macros.hpp to extend it with other macros required here.
This PR applied XSIMD_INLINE liberally, but because this is fragile, it also adds an inline namespace to SVE to prevent future (and unfound) violations.
Working with inline namespace is more tricky than I thought, so I had to rename all detail to detail_sve inside the header to avoid confusion.
Notes:
⚠️ This is an ABI break
I haven't yet applied the formatter as doing so will make it hard to review (I'll do
it right before merging when there is a approval).
I will send a similar PR for RVV which potentailly suffers from the same issue.
@JohanMabille, well in other files there are public utilities in namespacexsimd::kernel::detail.
In sve, they would be in xsimd::kernel::(sve128)::detail.
So with sve code invoking detail::something the compiler gets all confused and complains that something is not in xsimd::kernel::sve128::detail, without looking in xsimd::kernel::detail.
I tried all the using and full qualification I could, with no success. Best I could do is to explicitly name them differently.
Alternatively, we should say that anything in detail is header-private, and move the library-internal ones to xsimd::kernel::utils or something.
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
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.
Bug found when adding dynamic dispatch with both SVE128 and SVE256.
The issue is found was on:
Without
XSIMD_INLINE, in debug mode, two inline symbols were created and the linker pickedone (the one with
-msve-vector-length=16) and applied it everywhere.What changed:
xsimd_inline.hppwas renamedxsimd_macros.hppto extend it with other macros required here.XSIMD_INLINEliberally, but because this is fragile, it also adds aninline namespaceto SVE to prevent future (and unfound) violations.inline namespaceis more tricky than I thought, so I had to rename alldetailtodetail_sveinside the header to avoid confusion.Notes:
it right before merging when there is a approval).
@serge-sans-paille @JohanMabille