Skip to content

Conversation

kunalspathak
Copy link
Contributor

@kunalspathak kunalspathak commented Jul 5, 2024

  • AbsoluteCompareGreaterThan
  • AbsoluteCompareGreaterThanOrEqual
  • AbsoluteCompareLessThan
  • AbsoluteCompareLessThanOrEqual
  • CompareEqual
  • CompareGreaterThan
  • CompareGreaterThanOrEqual
  • CompareLessThan
  • CompareLessThanOrEqual
  • CompareNotEqualTo
  • CompareUnordered

Some changes are from @mikabl-arm contributions in #102611.

All stress tests are passing.

@ghost
Copy link

ghost commented Jul 5, 2024

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

1 similar comment
@ghost
Copy link

ghost commented Jul 5, 2024

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

@kunalspathak
Copy link
Contributor Author

@dotnet/arm64-contrib

@dotnet-policy-service
Copy link
Contributor

Tagging subscribers to this area: @dotnet/area-system-runtime-intrinsics
See info in area-owners.md if you want to be subscribed.

getLowVectorOperandAndCandidates(intrin, &lowVectorOperandNum, &lowVectorCandidates);
}

if ((intrin.id == NI_Sve_ConditionalSelect) && (intrin.op2->IsEmbMaskOp()) &&
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was dead code

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, looks like we handle embedded masks just above this snippet, right here.

Copy link
Contributor

@amanasifkhalid amanasifkhalid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

}

[method: MethodImpl(MethodImplOptions.AggressiveInlining)]
private void ConditionalSelectScenario_TrueValue({Op1VectorType}<{Op1BaseType}> mask, {Op1VectorType}<{Op1BaseType}> op1, {Op1VectorType}<{Op1BaseType}> op2, {Op1VectorType}<{Op1BaseType}> falseOp)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are a couple of cases in this template where the second operand uses Op1BaseType instead of Op2BaseType. This shouldn't cause any problems for now, since the APIs you're adding use operands of the same type. Should we fix this before checking the new template in, or should we wait to fix this once we add new APIs with different operand types (like what we've been doing for the last few)? I'm fine with either approach.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, perhaps it needs a audit for similar templates, so will probably do this on need basis.

@kunalspathak kunalspathak marked this pull request as ready for review July 5, 2024 16:47
@amanasifkhalid
Copy link
Contributor

Test changes LGTM, too.

@kunalspathak kunalspathak merged commit 5505150 into dotnet:main Jul 5, 2024
@kunalspathak kunalspathak deleted the AbsoluteCompare branch July 5, 2024 22:13
Comment on lines +1336 to +1339
if (HWIntrinsicInfo::ReturnsPerElementMask(node->GetHWIntrinsicId()))
{
nodeType = TYP_MASK;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this just be node->TypeGet() 100% of the time?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, will change it in follow-up PRs.

SingleTypeRegSet candidates = lowVectorOperandNum == 2 ? lowVectorCandidates : RBM_NONE;

if (intrin.op2->gtType == TYP_MASK)
if (intrin.op2->OperIsHWIntrinsic(NI_Sve_ConvertVectorToMask))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this change the register set to MASK but regular TYP_MASK nodes do not?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its the same reason I mentioned in #102611 (comment)

@github-actions github-actions bot locked and limited conversation to collaborators Aug 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants