-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Support for a scalable simd representation #118917
base: master
Are you sure you want to change the base?
Commits on Jul 24, 2024
-
The representation of the element type has been changed to be a slice rather than a zero length array. Two feature gates are now required in core_arch unsized fn params and unsized locals. This still leaves unsized return types being an issue. For this we are currently bypassing some of the `Sized` trait checking to pass when the type is scalable simd. This still leaves the copy issue. For that we have marked scalable simd types as trivally pure clone copy. We have still had to remove some trait checks for the copy trait with this though as they are still performed in certain situations. The implementation of `transmute` is also an issue for us. For this a new SIMD intrinsic has been created simd_reinterpret which performs a transmute on SIMD vectors. A few intrinsics need to be able to produce an LLVM `undef` this intrinsic will also produce that when given a zero sized input.
Configuration menu - View commit details
-
Copy full SHA for aee9788 - Browse repository at this point
Copy the full SHA aee9788View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6624e8a - Browse repository at this point
Copy the full SHA 6624e8aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 5869f9d - Browse repository at this point
Copy the full SHA 5869f9dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0324ff4 - Browse repository at this point
Copy the full SHA 0324ff4View commit details -
Restrict the spilling of scalable types to the problematic ones.
Rather than not spilling any scalable SIMD types for debug info, we only avoid spilling the ones that are going to cause a problem. Currently the only ones known to cause a problem are the internal svbool types for AArch64.
Configuration menu - View commit details
-
Copy full SHA for 0a956db - Browse repository at this point
Copy the full SHA 0a956dbView commit details -
Scalable SIMD tests for disallowing scalable types in types.
Tests to ensure that scalable SIMD types can't exist in struct, union, enum variants and compound types. This also changes the well formed checking of types to improve the error message when scalable SIMD types are included. The previous implementation would also allow a scalable SIMD type as the last element within a struct in some cases which we currently don't want to allow.
Configuration menu - View commit details
-
Copy full SHA for c4f8a92 - Browse repository at this point
Copy the full SHA c4f8a92View commit details -
Allow SVE types to be taken by reference.
Ensures that an SVE type can have a reference taken to it. This currently emits a `dereferenceable` attribute for the ptr using the element size as the number of bytes. While not perfect this is correct as a vector will always have a least one primitive.
Configuration menu - View commit details
-
Copy full SHA for dace184 - Browse repository at this point
Copy the full SHA dace184View commit details -
Configuration menu - View commit details
-
Copy full SHA for d5834cc - Browse repository at this point
Copy the full SHA d5834ccView commit details -
Don't require the user to enable the unsized features.
Rather than forcing the user to enable the unsized_fn_params and unsized_locals features, we condition those features tests with if the type is a scalable simd type.
Configuration menu - View commit details
-
Copy full SHA for e237c35 - Browse repository at this point
Copy the full SHA e237c35View commit details -
Add some comments explaining some not so obvious things. Mark code as unreachable on architectures that don't currently have scalable vectors. Remove some unused (and incorrect) checks that were being performed. Refactor some code to improve it's readability.
Configuration menu - View commit details
-
Copy full SHA for e23a944 - Browse repository at this point
Copy the full SHA e23a944View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1adf6ca - Browse repository at this point
Copy the full SHA 1adf6caView commit details -
Disallow scalable vectors in async fn.
Scalable vectors are unsized types so we can't hold them across an await point. Also clean up the tests to remove unsized features from tests as a user shouldn't have to enable them when using scalable vectors.
Configuration menu - View commit details
-
Copy full SHA for f18804e - Browse repository at this point
Copy the full SHA f18804eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 63f9d37 - Browse repository at this point
Copy the full SHA 63f9d37View commit details