summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2023-04-05 12:53:50 -0700
committerGitHub <noreply@github.com>2023-04-05 19:53:50 +0000
commit04d451f3aadaf4d364e001fa9a849ef57a100a9e (patch)
tree3f82300c68a64df93b455ce19a9969d2d3c5dbe6 /src
parentd21b6d04ff8020d76636ee0e09a8ccede9c0bf39 (diff)
downloadbinaryen-04d451f3aadaf4d364e001fa9a849ef57a100a9e.tar.gz
binaryen-04d451f3aadaf4d364e001fa9a849ef57a100a9e.tar.bz2
binaryen-04d451f3aadaf4d364e001fa9a849ef57a100a9e.zip
RemoveUnusedModuleElements: Add SIMD support for memory operations (#5632)
Fixes #5629
Diffstat (limited to 'src')
-rw-r--r--src/passes/RemoveUnusedModuleElements.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/passes/RemoveUnusedModuleElements.cpp b/src/passes/RemoveUnusedModuleElements.cpp
index 747b8806c..943448cfa 100644
--- a/src/passes/RemoveUnusedModuleElements.cpp
+++ b/src/passes/RemoveUnusedModuleElements.cpp
@@ -154,6 +154,12 @@ struct ReferenceFinder : public PostWalker<ReferenceFinder> {
void visitAtomicNotify(AtomicNotify* curr) {
note({ModuleElementKind::Memory, curr->memory});
}
+ void visitSIMDLoad(SIMDLoad* curr) {
+ note({ModuleElementKind::Memory, curr->memory});
+ }
+ void visitSIMDLoadStoreLane(SIMDLoadStoreLane* curr) {
+ note({ModuleElementKind::Memory, curr->memory});
+ }
void visitMemoryInit(MemoryInit* curr) {
note({ModuleElementKind::DataSegment, curr->segment});
note({ModuleElementKind::Memory, curr->memory});