-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Fix asserts that were always true due to a missed neg. #44095
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
The assert is failing on |
Will take a look, it's likely a simple fix. |
@sandreenko, I just added the following at L5467, just above the case NI_SSE2_ShiftLeftLogical128BitLane:
case NI_SSE2_ShiftRightLogical128BitLane:
case NI_AVX2_ShiftLeftLogical128BitLane:
case NI_AVX2_ShiftRightLogical128BitLane:
{
#if DEBUG
// These intrinsics should have been marked contained by the general-purpose handling earlier in the method.
GenTree* lastOp = HWIntrinsicInfo::lookupLastOp(node);
assert(lastOp != nullptr);
if (HWIntrinsicInfo::isImmOp(intrinsicId, lastOp) && lastOp->IsCnsIntOrI())
{
assert(lastOp->isContained());
}
#endif
break;
} Do you want me to push a new commit directly to the PR or would you like to just cherry-pick the change (or some variant) yourself? |
Please push your changes directly to this PR or you can open a new one and I will close this. |
…and marked contained
Thanks @tannergooding for the fix. |
case NI_AVX2_ShiftRightLogical128BitLane: | ||
{ | ||
#if DEBUG | ||
// These intrinsics should have been marked contained by the general-purpose handling earlier in the method. |
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.
This is causing CI to fail in the formatting job. It failed on this PR as well.
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 you fixed this in #44197, 👍
It took me a while to understand how in #43397 (comment) we did not fail on
assert("Unhandled containment for ternary hardware intrinsic with immediate operand");
cc @janvorli