[llvm] [LoongArch] Lower ANY_EXTEND to ZERO_EXTEND under LASX to avoid scalarization (PR #201099)

via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 2 19:31:44 PDT 2026


lrzlin wrote:

> Can we achieve the same goal by overriding `isZExtFree` instead?

I don't think `isZExtFree` is suitable for this purpose, it's unrelated with `ANY_EXTEND`, other backends like X86 implement `isZExtFree` and `ANY_EXTEND` lowering at the same time.

> It would be helpful to explain in the comment why `ANY_EXTEND` is being replaced with `ZERO_EXTEND`.
> 
> Please add a test for this.

I'll do it, thanks.

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


More information about the llvm-commits mailing list