<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/60963>60963</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[WebAssembly] Invalid code generated with memory64 + simd
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
tlively
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
sbc100
</td>
</tr>
</table>
<pre>
Previously we had a crash bug: https://github.com/llvm/llvm-project/issues/57577.
Now that that is fixed I tried to re-enable the simd+memory64 test in emscripten and ran into an validation issue.
To reproduce you can run this command from an emscripten checkout:
```
$ ./em++ test/sse/test_sse2.cpp -sMEMORY64 -Wno-experimental -msimd128 -fno-lax-vector-conversions -Itest/sse -msse2
$ wasm-dis a.out.wasm
[parse exception: attempted pop from empty stack / beyond block start boundary at 35029 (at 0:35029)]
Fatal: error parsing wasm (try --debug for more info)
$ wasm-validate --enable-all a.out.wasm
a.out.wasm:00088d5: error: type mismatch in drop, expected [any] but got []
a.out.wasm:0008960: error: type mismatch in drop, expected [any] but got []
a.out.wasm:0008bbb: error: type mismatch in drop, expected [any] but got []
a.out.wasm:0008c46: error: type mismatch in drop, expected [any] but got []
a.out.wasm:0009eb7: error: type mismatch in drop, expected [any] but got []
a.out.wasm:0009fba: error: type mismatch in drop, expected [any] but got []
...
````
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy0VU1v4zYQ_TX0ZSCBpizJOvhgNxWQw7ZFUWDRU8GPscWGIgVyZEf_vqDsTbLtrdgABq2hxPfmDTmPMiV78YgHVp-YEOTsFd3ChGD100bONIR4SEpvOd-oYJbDbxGvNszJLXBDGKQBCTrKNICaL6w6wkA0JVYdmeiZ6C-WhlmVOoxM9M5dv_0VUwx_oyYmepvSjImJvm7rti0Zf2L8eB9_CTegQdJ9sAnO9hUNPANFiwYoQMQCvVQOgQaEZEfDxGnEMcSl2QFhIrAecEw62onQg_QGovRgPQWQHq7SWSPJBg9rIt_x_5EJphjMrBGWMIOWHuLsgQabQIdxzHDnGMYM9YFFD6hfwky5Dh_wWMMfv3sodlAy0ePIxImJ05ovE31KyESfg79SQlHqaYIiffn5y6-__9nsoPjqQ4GvE0Y7oifpoBiz8q3YQ3H2oXDytbiiphALHfwVY7LBJyie3_HzkoTiPY-bTGNhbAJZhpnKHD5e1qdJxoSArxqnXKi8y5IIx4nQwBSmewVyvEAiqV-AiR4ULsEbUC7olzwdCVSYvZFxAUlQ1Vx0wMReEnBWHdeYiY7VT3fiXpJ0mQtjDBFyEtZf1kTzMooLFIVBNV_gHCKMISJYfw4Z43tZjz1GKB6HpZDOfRAK9-8_KK-OnPP93tRv_PmBlglhtGmUpId8rkwMExM_Qd4MnYvB6pP0C6ufQM0El0B55k3Rfwi6hn8ugVLqcwn0rvlUgg5V-7kEZyV_KEFZlv9u9m_9vjGHynRVJzd42DZtKzhvum4zHOqtbvlWmc7UVVOptq3PXbPfN_W2E02l-cYeBBcVF2LHt3xXd6WpGmFQNEY3VbsXLdtxHKV1ZTbXMsTLZnWzQ8O7pto4qdClh8V7vN2t7mHy8bAaspovie24s4nSOwpZcuvd8BXVMSUclVuVP_u1qUAHg3BBj1Hm0twsDfBmv9nSsjFt5ugO__9eWDX8EwAA___TLRqQ">