This is an archive of the discontinued LLVM Phabricator instance.

[mlir] Add support for TF32 as a Builtin FloatType
ClosedPublic

Authored by jfurtek on Jun 24 2023, 9:32 AM.

Details

Summary

This diff adds support for TF32 as a Builtin floating point type. This
supplements the recent addition of the TF32 semantic to the LLVM APFloat class
by extending usage to MLIR.

https://reviews.llvm.org/D151923

More information on the TF32 type can be found here:

https://blogs.nvidia.com/blog/2020/05/14/tensorfloat-32-precision-format/

Diff Detail

Event Timeline

jfurtek created this revision.Jun 24 2023, 9:32 AM
Herald added a reviewer: ftynse. · View Herald Transcript
Herald added a project: Restricted Project. · View Herald Transcript
jfurtek requested review of this revision.Jun 24 2023, 9:32 AM
jpienaar accepted this revision.Jun 29 2023, 9:54 PM

Looks good, thanks

mlir/include/mlir/IR/BuiltinTypes.h
46

Nit: order below F32

mlir/include/mlir/IR/BuiltinTypes.td
202

Copy pasta?

This revision is now accepted and ready to land.Jun 29 2023, 9:54 PM
jfurtek updated this revision to Diff 537360.Jul 5 2023, 8:15 AM
  • Fix declaration order and incorrect comment
jfurtek marked 2 inline comments as done.Jul 5 2023, 8:16 AM
This revision was automatically updated to reflect the committed changes.