[all-commits] [llvm/llvm-project] 3a3377: [mlir][math]Update `convertPowfOp` `ExpandPatterns...
Hyunsung Lee via All-commits
all-commits at lists.llvm.org
Tue Jan 28 19:57:06 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 3a3377579f137a0a6e14b60d891a9736707e7e8d
https://github.com/llvm/llvm-project/commit/3a3377579f137a0a6e14b60d891a9736707e7e8d
Author: Hyunsung Lee <ita9naiwa at gmail.com>
Date: 2025-01-28 (Tue, 28 Jan 2025)
Changed paths:
M mlir/lib/Dialect/Math/Transforms/ExpandPatterns.cpp
M mlir/test/Dialect/Math/expand-math.mlir
M mlir/test/mlir-runner/test-expand-math-approx.mlir
Log Message:
-----------
[mlir][math]Update `convertPowfOp` `ExpandPatterns.cpp` (#124402)
The current implementation of `convertPowfOp` requires a calculation of
`a * a` but, max\<fp16\> ~= 65,504, and if `a` is about 16, it will
overflow so get INF in fp8 or fp16 easily.
Remove support when `a < 0`. Overhead of handling negative value of `a`
is large and easy to overflow;
- related issue in iree:
https://github.com/iree-org/iree/issues/15936
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list