Add 128-bit SIMD implementation for LoongArch#592
Add 128-bit SIMD implementation for LoongArch#592Amanieu merged 1 commit intorust-lang:masterfrom heiher:loong-lsx
Conversation
BenchmarksGenericLSX |
src/control/group/lsx.rs
Outdated
| /// Returns a `BitMask` indicating all tags in the group which are full. | ||
| #[inline] | ||
| pub(crate) fn match_full(&self) -> BitMask { | ||
| self.match_empty_or_deleted().invert() |
There was a problem hiding this comment.
Would it be faster to use lsx_vmskgez_b here?
There was a problem hiding this comment.
Yes, it would definitely be faster to use lsx_vmskgez_b here. Good catch!
|
Blocked by rust-lang/rust#133249 |
| } else if #[cfg(all( | ||
| target_arch = "loongarch64", | ||
| target_feature = "lsx", | ||
| not(miri), |
There was a problem hiding this comment.
This should be under the "nightly" feature until loongarch intrinsics are stabilized.
There was a problem hiding this comment.
I was also going to mention this-- that way loongarch still works on stable. Although it would also be nice to have a new release so this can be used for the libstd implementation.
| pub(crate) const fn static_empty() -> &'static [Tag; Group::WIDTH] { | ||
| #[repr(C)] | ||
| struct AlignedTags { | ||
| _align: [Group; 0], | ||
| tags: [Tag; Group::WIDTH], | ||
| } | ||
| const ALIGNED_TAGS: AlignedTags = AlignedTags { | ||
| _align: [], | ||
| tags: [Tag::EMPTY; Group::WIDTH], | ||
| }; | ||
| &ALIGNED_TAGS.tags | ||
| } |
There was a problem hiding this comment.
Depending on the outcome of #596 you may want to add that change here as well.
|
☔ The latest upstream changes (presumably #597) made this pull request unmergeable. Please resolve the merge conflicts. |
CI is green now. |
No description provided.