[llvm] [WebAssembly] Enable multivalue return when multivalue ABI is used (PR #88492)

Heejin Ahn via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 12 17:32:51 PDT 2024


aheejin wrote:

Sorry that I deleted the previous comments (In case people are reading replies from emails I thought modifying the comment was not gonna be reflected, so I'm writing a new one instead of modifying the previous ones)

This is effectively a backend-only change and it controls non-libcall multivalue return lowering too (See changes in `WebAssemblyISelLowering.cpp` and `WebAssemblyMachineFunctionInfo.cpp`). We talked about how to relay the frontend's ABI info to the backend but in turned out it was already being passed in `MCTargetOptions`.

This will affect compilation of
- Bitcode files that have struct returns
- Multivalue-returning invokes (which I tried to ban in #86048)
- i128-returning functions

In practice there will not be many people who compile bitcodes, and we don't support multivalue-returning invokes anyway, but i128-returning functions will be affected by this change that can't be controlled by the frontend experimental-mv option, which this PR lowers down to pointer-passing returns.

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


More information about the llvm-commits mailing list