-
Notifications
You must be signed in to change notification settings - Fork 5k
ISimdVector vector intrinsics fixes #113288
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
Conversation
1e58c80
to
13d6a60
Compare
13d6a60
to
d7bffcc
Compare
ebcc1fb
to
4f79607
Compare
934ec82
to
b6f4172
Compare
b6f4172
to
b3560ab
Compare
418452e
to
ddb2b8f
Compare
done |
Tagging subscribers to this area: @BrzVlad, @kotlarmilos |
Tagging subscribers to this area: @steveisok, @vitek-karas |
Tagging subscribers to this area: @dotnet/area-system-runtime-intrinsics |
04516ad
to
35bfdea
Compare
750fdc6
to
f318510
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes the filtering for explicit ISimdVector implementations by addressing the incorrect namespace used for the Vector intrinsics. Key changes include adjusting the string slicing for processing method names and adding a new branch to handle the Runtime.Intrinsics.Vector namespace.
Comments suppressed due to low confidence (1)
src/coreclr/tools/Common/JitInterface/CorInfoImpl.cs:4442
- Consider using an 'else if' here if the 'Numerics.Vector' branch is mutually exclusive, to prevent potential double processing of the method name.
if (partialMethodName.StartsWith("Runtime.Intrinsics.Vector"))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me and I agree with this capturing the original intent, but we should get signoff from a jit expert.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. It's a bit unfortunate that we use magic constants here, any C++ compiler should be able to constant fold strlen("const")
, but it's out of the scope of this PR
(strncmp(cmethod_name + 70, "256<T>,T>.", 10) == 0) || | ||
(strncmp(cmethod_name + 70, "512<T>,T>.", 10) == 0)) { | ||
cmethod_name += 80; | ||
if (strncmp(cmethod_name, "System.Runtime.Intrinsics.ISimdVector<System.", 45) == 0) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like we duplicate this code block 3 times, maybe put it into some shared function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides the code duplication it LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
(Sorry for the delay, was out last week)
#104983 added filtering for explicit ISimdVector implementations. It appears it used the wrong namespace for
System.Numerics.Vector<T>
when removing the expanded interface and types from the method name. Fix the explicit interface implementation filtering and call SN Vector interpreter intrinsics.