This intrinsic selects v_mad_f32 regardless of fp32 denorm support.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | Does v_mad_f16 flush denormals? I don't think it does |
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | It does. It cannot preserve denormals. It is even lowered into FMAD_FTZ, which is lowered to mad. The new part is this intrinsic sitting above the existing SDNode. |
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | In that case I would make this intrinsic type mangled and make it work for f16 as well |
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | AFAIR f16 does not flush. |
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | Sorry for confusion: v_mad_f32 flushes. v_mad_f16 does not. That is why it is not overloaded. |
Comment Actions
Actually according to the selection code, f16 mad does not support denormals the same, so the intrinsic should work with f16 if that is correct
Comment Actions
Perhaps fixes needed.
include/llvm/IR/IntrinsicsAMDGPU.td | ||
---|---|---|
364 ↗ | (On Diff #152788) | According to SCDevUtil/SCMathengine, V_MAD_F16 always flushes HP denormals. Please double-check. |