[llvm] [MachineSink] Add option for aggressive loop sinking (PR #117247)
Jeffrey Byrnes via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 22 13:54:38 PST 2024
================
@@ -0,0 +1,20 @@
+; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx942 --aggressively-sink-insts-to-avoid-spills=1 < %s | FileCheck -check-prefix=SUNK %s
+
+; Check that various edge cases do not crash the compiler
+
+; Multiple uses of sunk valu, chain of sink candidates
+
+define half @global_agent_atomic_fmin_ret_f16__amdgpu_no_fine_grained_memory(ptr addrspace(1) %ptr, half %val) {
+; SUNK-LABEL: global_agent_atomic_fmin_ret_f16__amdgpu_no_fine_grained_memory:
----------------
jrbyrnes wrote:
Sure, but this test was added to test inputs with various details that the algorithm needed to account for, and not to test the generated code. Later passes (machine-licm, si-fold-operands, etc) mask the effect of the flag such that the codegen is the same with / without.
https://github.com/llvm/llvm-project/pull/117247
More information about the llvm-commits
mailing list