[PATCH] D62877: [WebAssembly] Implement tail calls and unify tablegen call classes

Heejin Ahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 9 15:41:07 PDT 2019


aheejin added inline comments.


================
Comment at: llvm/test/CodeGen/WebAssembly/tailcall.ll:120
+define i32 @mismatched_prototypes() {
+  %v = tail call i32 @baz(i32 0, i32 42, i32 6)
+  ret i32 %v
----------------
tlively wrote:
> aheejin wrote:
> > Not sure what this tests..? The function name is `mismatched_prototypes` but the prototypes here match. And the comment says `musttail requires ...` but this is not a `musttail` but a `tail`. The same for other methods below.
> The prototypes of the caller and callee do not match. Using `musttail` here would be an LLVM validation error, but we can still test with `tail`, and similar for the following tests. I'll clarify the comments.
Sorry, but don't they match..?
Declaration:
```
declare i32 @baz(i32, i32, i32)
```
Call:
```
tail call i32 @baz(i32 0, i32 42, i32 6)
```



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D62877





More information about the llvm-commits mailing list