This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][RISCV][SelectionDAG] Support VECREDUCE_ADD mask operations
AbandonedPublic

Authored by Jimerlife on May 10 2022, 5:22 AM.

Details

Summary

D125206 patch make CodeGen/AArch64/vecreduce-add-legalization.ll fail, So I revert it. Now I have update vecreduce-add-legalization.ll in this patch.

Diff Detail

Event Timeline

Jimerlife created this revision.May 10 2022, 5:22 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 10 2022, 5:22 AM
Jimerlife requested review of this revision.May 10 2022, 5:22 AM

Other than a minor nit the patch looks sensible. However, there's a clear regression that needs resolving first.

llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
5315

This comment doesn't offer any real value. None of the canonicalisation above and below this one are commented so perhaps no comment it necessary.

I've created D125605 that once landed should mean this patch will no longer negatively affect AArch64 code generation.

Jimerlife updated this revision to Diff 429597.May 15 2022, 7:34 PM

address comment

Jimerlife marked an inline comment as done.May 15 2022, 7:35 PM
Jimerlife added inline comments.
llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
5315

Thanks, I removed this comment

reames added a subscriber: reames.May 16 2022, 8:09 AM

Please go ahead and land the new tests, and then rebase so that changes in codegen are visible in review. Also, please rebase over the mentioned Aarch64 review. The test diff there currently looks like a regression because you haven't stacked the changes which was confusing at first.

The submission comment needs improved to describe what this is actually doing.

The patch seems generally reasonable. Once the above are done, should be an easy LGTM.

Jimerlife updated this revision to Diff 429918.May 16 2022, 7:08 PM
Jimerlife marked an inline comment as done.

rebase main. After D125605 landed, this patch will no longer negatively affect AArch64 code generation.

Please go ahead and land the new tests, and then rebase so that changes in codegen are visible in review. Also, please rebase over the mentioned Aarch64 review. The test diff there currently looks like a regression because you haven't stacked the changes which was confusing at first.

The submission comment needs improved to describe what this is actually doing.

The patch seems generally reasonable. Once the above are done, should be an easy LGTM.

Thanks for your advice. After I rebased main, this patch no longer affect AArch64 tests.

reames requested changes to this revision.May 16 2022, 7:49 PM

Previous comments unaddressed

This revision now requires changes to proceed.May 16 2022, 7:49 PM

Please go ahead and land the new tests, and then rebase so that changes in codegen are visible in review. Also, please rebase over the mentioned Aarch64 review. The test diff there currently looks like a regression because you haven't stacked the changes which was confusing at first.

The scalable vector tests crash right now so they can't be pre-comitted.

Please go ahead and land the new tests, and then rebase so that changes in codegen are visible in review. Also, please rebase over the mentioned Aarch64 review. The test diff there currently looks like a regression because you haven't stacked the changes which was confusing at first.

The scalable vector tests crash right now so they can't be pre-comitted.

Then the submission comment needs to mention that.

Please go ahead and land the new tests, and then rebase so that changes in codegen are visible in review. Also, please rebase over the mentioned Aarch64 review. The test diff there currently looks like a regression because you haven't stacked the changes which was confusing at first.

The submission comment needs improved to describe what this is actually doing.

The patch seems generally reasonable. Once the above are done, should be an easy LGTM.

Thanks for your advice. After I rebased main, this patch no longer affect AArch64 tests.

I misunderstood what you meant before.In RISCV, VECREDUCE_ADD mask operations is unsupport, so I cann't precommit scalable vector tests. Before D125605 landed, my patch affect a AArch64 test(vecreduce-add-legalization.ll), but now this is no affect after D125605 landed.

Given this all started by the revert of D125206 and the reason it was reverted has now been resolved, perhaps you should just re-land D125206?

Given this all started by the revert of D125206 and the reason it was reverted has now been resolved, perhaps you should just re-land D125206?

Thanks for your support. I will re-land D125206 and abandon this patch.

Jimerlife abandoned this revision.May 19 2022, 1:07 AM