pfusik wrote: > Here's another case that might be useful to optimize https://godbolt.org/z/MEzP15sas it already generates a `not` but we don't fold it. Done. Covered by the `andimm64srli` test. https://github.com/llvm/llvm-project/pull/120221