[PATCH] D122215: [WebAssembly] Initial support for reference type externref in clang

Moritz Sichert via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 16 01:12:01 PST 2022


MoritzS added a comment.

In D122215#3998105 <https://reviews.llvm.org/D122215#3998105>, @pmatos wrote:

> In D122215#3991648 <https://reviews.llvm.org/D122215#3991648>, @MoritzS wrote:
>
>> Thanks for the patch! I just tried it out and I think this enables many interesting use cases for WebAssembly when using C/C++.
>>
>> Currently the lowering to wasm does not work when using externrefs when compiling without optimizations. Is that intended behavior?
>
> I have posted a new patch that fixed this. Can you please try it again and see if it works as you expect?

Thanks for the quick update, it works now!

Does this affect the debugging experience of the generated wasm programs? If you force mem2reg to run for all programs, no function arguments will be written to the "stack" referenced by the __stack_pointer global variable anymore. I don't know whether any wasm runtime actually uses that for debugging, though.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D122215/new/

https://reviews.llvm.org/D122215



More information about the cfe-commits mailing list