When I optimize the attached .wasm with the current main branch (9792f2c) using this invocation:
wasm-opt \
-g \
--all-features \
--closed-world \
--traps-never-happen \
--type-unfinalizing \
-Os \
--type-ssa \
--gufa \
-Os \
--type-merging \
-Os \
--type-finalizing \
test.wasm -o test.opt.wasm
The generated .wasm has 34 instruction sequences of drop; unreachable.
In those cases the drop instruction could be dropped.
test.wasm.zip