This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Fix incorrect codegen for masked vmsge{u}.vx with mask agnostic.
ClosedPublic

Authored by khchen on Apr 29 2022, 9:42 AM.

Details

Summary

The result was totally wrong.
We could use mask undisturbed result to emulate the mask agnostic result.

Diff Detail

Event Timeline

khchen created this revision.Apr 29 2022, 9:42 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 29 2022, 9:42 AM
khchen requested review of this revision.Apr 29 2022, 9:42 AM
craig.topper accepted this revision.Apr 29 2022, 10:21 AM

LGTM

llvm/test/CodeGen/RISCV/rvv/masked-tama.ll
1435

Will we eventually be able to use 'ma' here?

This revision is now accepted and ready to land.Apr 29 2022, 10:21 AM
kito-cheng added inline comments.Apr 29 2022, 7:51 PM
llvm/test/CodeGen/RISCV/rvv/masked-tama.ll
1435

Sounds like that what we can optimized in vsetvli insertion?

khchen added inline comments.May 2 2022, 6:58 PM
llvm/test/CodeGen/RISCV/rvv/masked-tama.ll
1435

Yes, I think I could try to add ForceMaskAgnostic or optimize InsertVSETVLI in follow-up patch.