llvm-project
4e95be70 - [RFC][SPIR-V] Add intrinsics to convert to/from ap.float (#164252)

Commit
52 days ago
[RFC][SPIR-V] Add intrinsics to convert to/from ap.float (#164252) The patch adds two intrinsics: llvm.convert.to.arbitrary.fp and llvm.convert.from.arbitrary.fp. The intrinsics perform conversions between values whose interpretation differs from their representation in LLVM IR. The intrinsics are overloaded on both its return type and first argument. Metadata operands describe how the raw bits should be interpreted before and after the conversion. Typical use case is to convert IEEE-754 floating point types to FP8/FP4 and backwards for ML applications. Addresses https://discourse.llvm.org/t/rfc-spir-v-way-to-represent-float8-in-llvm-ir/87758/10
Author
Parents
Loading