[llvm] [AArch64][SVE2] Lower read-after-write mask to whilerw (PR #114028)

David Green via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 7 00:57:58 PST 2024


https://github.com/davemgreen commented:

I think this might be difficult mathematically to make fit correctly. I believe that if you pass this a very high value and a very low one (say 0xfffffffffffffff8 and 0), the whilewr will zext both results so the "is negative" part will be different than if you had done it all with i64 arithmetic. The result of 0xfffffffffffffff8-0 is negative in i64, zext(0xfffffffffffffff8)-zext(0) isn't.

That might not be very important for pointers as it is only the very top bits + very bottom bits that would be negative and not outside of a vector width. I don't think we can just rule it out though, as we are matching from any i64s.

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


More information about the llvm-commits mailing list