[PATCH] D89797: [WebAssembly] Implementation of (most) table instructions

Paulo Matos via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 20 08:32:15 PDT 2020


pmatos added a comment.

So the goal here is to add most of the table instructions. This introduces some table relocations, which (in a following patch) we will resolve in the linker.

I have some concerns with this patch. The tests here are testing that instructions table.* written in .s files will be assembled properly into an object file. However, there are no tests actually testing the register based part of the instruction definitions.

So, for example for table.grow, I am unsure that

  (outs i32imm_op:$sz), (ins table32_op:$table, i32imm_op:$n, reftype_op:$val)

actually makes sense for the register based version of the instruction and I have no tests actually looking into it since I have been mostly concerned at assembler level.
I assume that we cannot test this atm since register-level is relevant at the codegen part and we have no way to represent in IR a table.grow operation.

Should we add intrinsics for these? and try to test this at codegen level? or just add a comment pointing out that register-level instruction definitions are currently untested? or something else? Suggestions welcome.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D89797



More information about the llvm-commits mailing list