Conversation
|
Apparently I'm not affiliated, that's fine. I release this change into the public domain. |
rossberg
left a comment
There was a problem hiding this comment.
Thanks, looks good. But while you're doing this, why not add one with 100 arguments? That would be a particularly interesting thing to test!
test/core/call.wast
Outdated
| ;; Test correct argument passing | ||
|
|
||
| (func $return-arg-0-helper (param i32) (result i32) | ||
| (local.get 0) |
There was a problem hiding this comment.
Nit: consistent indentation (here and below)
|
Thanks for reviewing, I'll make those changes! |
|
Okay I made the changes, just a note, I did not verify if the reference interpreter passed this test. |
|
Ah, sorry, that was a misunderstanding. I didn't mean to suggest to enumerate all possible parameter lengths up to 100, just add one test with 100. Enumerating all cases feels like overkill and makes the test file difficult to manoeuvre. Also, it might be good to make this one "big" call test a bit more diverse and mix different parameter types randomly. That is the kind of thing that compilers tend to have problems with when compiling for different calling conventions. |
|
Oops yeah that was a bit of a reading comprehension fail on my part. I simplified the PR to a single new test. I removed the other tests because this single test was sufficient for my original purposes while also being interesting enough to have wider applicability. |
This change adds tests to make sure passing many arguments across "call" instructions is correct.