[clang] [llvm] Match bitsin(typeof(x)) - popcnt(x) to s_bcnt0_i32 on AMDGPU (PR #164847)

Jay Foad via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 29 02:48:50 PDT 2025


================
@@ -1884,6 +1886,13 @@ def : GCNPat <
      (S_MOV_B32 (i32 0)), sub1))
 >;
 
+def : GCNPat <
+   (i64 (UniformBinFrag<sub> 64, (UniformUnaryFrag<ctpop> i64:$src))),
----------------
jayfoad wrote:

Same here.

https://github.com/llvm/llvm-project/pull/164847


More information about the cfe-commits mailing list