This commit fixes T16180 on wasm once TH support is flipped on. The fix is simply adding right asm code for wasm. (cherry picked from commit 69bb4745) (cherry picked from commit ddff1975)