Mesa (master): aco: don't create v_mad_f32 on GFX10.3
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Tue Aug 4 22:04:28 UTC 2020
Module: Mesa
Branch: master
Commit: 4f1242a4d8c6e0be22565a03a8d5b8ea19c3382d
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4f1242a4d8c6e0be22565a03a8d5b8ea19c3382d
Author: Rhys Perry <pendingchaos02 at gmail.com>
Date: Tue Jun 16 17:43:01 2020 +0100
aco: don't create v_mad_f32 on GFX10.3
Signed-off-by: Rhys Perry <pendingchaos02 at gmail.com>
Reviewed-by: Daniel Schürmann <daniel at schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5546>
---
src/amd/compiler/aco_optimizer.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/amd/compiler/aco_optimizer.cpp b/src/amd/compiler/aco_optimizer.cpp
index c1f0bc20f9e..d060f378fe2 100644
--- a/src/amd/compiler/aco_optimizer.cpp
+++ b/src/amd/compiler/aco_optimizer.cpp
@@ -2614,7 +2614,7 @@ void combine_instruction(opt_ctx &ctx, Block& block, aco_ptr<Instruction>& instr
instr->opcode == aco_opcode::v_sub_f16 ||
instr->opcode == aco_opcode::v_subrev_f16;
if (mad16 || mad32) {
- bool need_fma = mad32 ? block.fp_mode.denorm32 != 0 :
+ bool need_fma = mad32 ? (block.fp_mode.denorm32 != 0 || ctx.program->chip_class >= GFX10_3) :
(block.fp_mode.denorm16_64 != 0 || ctx.program->chip_class >= GFX10);
if (need_fma && instr->definitions[0].isPrecise())
return;
More information about the mesa-commit
mailing list