[PATCH] D99505: [AMDGPU] Enable output modifiers for double precision instructions

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 30 11:24:25 PDT 2021


arsenm added inline comments.


================
Comment at: llvm/test/CodeGen/AMDGPU/omod.ll:102-103
+define amdgpu_ps void @v_omod_div2_f64(double %a) #5 {
+  %add = fadd fast double %a, 1.0
+  %div2 = fmul fast double %add, 0.5
+  store double %div2, double addrspace(1)* undef
----------------
Should just use the minimum set of fast flags


================
Comment at: llvm/test/CodeGen/AMDGPU/omod.ll:120-121
+define amdgpu_ps void @v_omod_mul2_f64(double %a) #5 {
+  %add = fadd fast double %a, 1.0
+  %div2 = fmul fast double %add, 2.0
+  store double %div2, double addrspace(1)* undef
----------------
Should just use the minimum set of fast flags


================
Comment at: llvm/test/CodeGen/AMDGPU/omod.ll:138-139
+define amdgpu_ps void @v_omod_mul4_f64(double %a) #5 {
+  %add = fadd fast double %a, 1.0
+  %div2 = fmul fast double %add, 4.0
+  store double %div2, double addrspace(1)* undef
----------------
Should just use the minimum set of fast flags


================
Comment at: llvm/test/CodeGen/AMDGPU/omod.ll:376
+attributes #5 = { nounwind "denormal-fp-math"="preserve-sign,preserve-sign" "no-signed-zeros-fp-math"="true" }
+attributes #6 = { nounwind "denormal-fp-math"="ieee,ieee" "no-signed-zeros-fp-math"="true" }
 
----------------
You're using the fast math flags, so you don't need the global no-signed-zeros-fp-math


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99505/new/

https://reviews.llvm.org/D99505



More information about the llvm-commits mailing list