This is an archive of the discontinued LLVM Phabricator instance.

[mlir][tosa] Use math.ctlz intrinsic for tosa.clz
ClosedPublic

Authored by rsuderman on May 13 2022, 4:33 PM.

Details

Summary

We were custom counting per bit for the clz instruction. Math dialect
now has an intrinsic to do this in one instruction. Migrated to this
instruction and fixed a minor bug math-to-llvm for the intrinsic.

Diff Detail

Event Timeline

rsuderman created this revision.May 13 2022, 4:33 PM
Herald added a reviewer: sjarus. · View Herald Transcript
Herald added a project: Restricted Project. · View Herald Transcript
rsuderman requested review of this revision.May 13 2022, 4:33 PM
rsuderman updated this revision to Diff 429386.May 13 2022, 4:34 PM

Removed the old implementation.

mravishankar accepted this revision.May 15 2022, 9:04 PM
This revision is now accepted and ready to land.May 15 2022, 9:04 PM