[PATCH] D67784: [WebAssembly] vNxM.load_splat instructions
Heejin Ahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 23 08:31:35 PDT 2019
aheejin accepted this revision.
aheejin added a comment.
This revision is now accepted and ready to land.
Mostly LGTM. By the way this contains diff of D67783 <https://reviews.llvm.org/D67783> as well.
================
Comment at: llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td:62
+ let mayLoad = 1, UseNamedOperandTable = 1,
+ Predicates = [HasUnimplementedSIMD128] in
+ defm LOAD_SPLAT_#vec :
----------------
I asked the same question in D67783, but why do we not need `SIMD128`? Other parts below too
================
Comment at: llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td:75
+
+def wasm_load_splat_t : SDTypeProfile<1, 1, []>;
+def wasm_load_splat : SDNode<"WebAssemblyISD::LOAD_SPLAT", wasm_load_splat_t>;
----------------
Don't we need `SDTCisPtrTy<0>`?
================
Comment at: llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td:78
+
+foreach args = [["v16i8", "i32", "extloadi8"], ["v8i16", "i32", "extloadi16"],
+ ["v4i32", "i32", "load"], ["v2i64", "i64", "load"],
----------------
Do we only do zero extension for splats?
================
Comment at: llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td:83
+ PatFrag<(ops node:$addr), (wasm_load_splat
+ (!cast<ValueType>(args[1]) (!cast<PatFrag>(args[2]) node:$addr)))>;
+
----------------
Didn't know we can use `foreach` like this :D
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67784/new/
https://reviews.llvm.org/D67784
More information about the llvm-commits
mailing list