<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/84541>84541</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[RISCV] Crash on FP unmasked Intrinsic::riscv_masked_strided_load with stride 0
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
topperc
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
topperc
</td>
</tr>
</table>
<pre>
An unmasked stride 0 load is handled as
```
MVT ScalarVT = ContainerVT.getVectorElementType();
SDValue ScalarLoad =
DAG.getExtLoad(ISD::ZEXTLOAD, DL, XLenVT, Load->getChain(), Ptr,
ScalarVT, Load->getMemOperand());
Chain = ScalarLoad.getValue(1);
Result = lowerScalarSplat(SDValue(), ScalarLoad, VL, ContainerVT, DL, DAG,
Subtarget);
```
But this doens't work if the scalar type is FP.
CC: @wangpc-pp @preames @lukel97
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyEU81uszoUfBqzsRIROwRYsKCQVJVStWoiVN1NZeAEfOsYZB-a27e_MtAvUVX1O4r8E9vjmcEjrJWNBkhIcEcYw67vwVSEMRLknhiw7Uwy_-mVXf2ZpJoO-izsO9TUopE1UJ-qTtRUWtoKXSuoqbDEz4mfzu3Gn3_jlI71WBzpoRJKmOJICc9p1mkUUoMpjssGsIAKO7NVcAaNx88eCIsIiwm_o7cwh7wQaoAZau94OLDbLa7y9N6Bbv9Dt4Ww6OGQE54Snv6zfT3un9KcsIzme9e-7kEXRzdyexeEbxvArBVSzxRYRp_RuG6q75d9qy-V3xAf4fzUgxG6_oIdxf1ct1eMVEaVV9GjY84IwqLVr0i_wb-AHRSO0Kq7gJnwD70SSFg0W3014Xq9mxWjeTdf8epont677i8-fdk1lChMAzjJ-PEJTe3dgBRbaWndgbaEhUgvnXmn8kSxBWpHehQ_e3Bvc_e8vD2cZYSnlKz9i9BNXy363k16A-IM1g3V8A4qDqlXJ7yOeSw8SFahH8csiBj32iQMY346BVEpNnHI-GrjB0EUhLVfxqeQV6EnE-aztc_9aBUzvuZLxqMoKCPG4hhCfxOTtQ9nIdVSqY_zsjONJ60dIInWwXrlKVGCsnMwNVzouDhH0yTuzKIcGuu4Sov2ioIS1Zjol4dDVpAgp5kRtqWdprvna3wfNBqpraymJBhpq4-3ae1tinb9Nib7IrH9E3ZvMCppEXvrjrEdYbtGYjuUy6o7E7ZzLOZu0ZvuX6iQsN3I3RK2G7X9HwAA____QkOD">