[MLIR][STD] Add safe scalar constant propagation for FPTruncOp
Perform scalar constant propagation for FPTruncOp only if the resulting value can be represented without precision loss or rounding. Example: %cst = constant 1.000000e+00 : f32 %0 = fptrunc %cst : f32 to bf16 --> %cst = constant 1.000000e+00 : bf16 Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D107518
Loading
Please sign in to comment