<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/64404>64404</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[RISC-V] disambiguation error of rvv intrinsic vector-scalar calls with fixed-length vector type
</td>
</tr>
<tr>
<th>Labels</th>
<td>
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
garthlei
</td>
</tr>
</table>
<pre>
Code:
``` c
#include <riscv_vector.h>
typedef vint64m1_t __attribute__((riscv_rvv_vector_bits(128))) vint64m1_128_t;
int main() {
vint64m1_t a;
vint64m1_128_t b;
vint64m1_t c = __riscv_vand(a, 0, 0);
vint64m1_t d = __riscv_vand(b, 0, 0);
}
```
Compiler message (`clang -march=rv64gcv -mrvv-vector-bits=128 -S test.c`):
```
test.c:9:18: error: call to '__riscv_vand' is ambiguous
9 | vint64m1_t d = __riscv_vand(b, 0, 0);
| ^~~~~~~~~~~~
test.c:9:18: note: candidate function
test.c:9:18: note: candidate function
test.c:9:18: note: candidate function
test.c:9:18: note: candidate function
test.c:9:18: note: candidate function
test.c:9:18: note: candidate function
1 error generated.
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzsVMuO6zYM_Rp5QzjQw47thReZZAJ02wG6NWRJsVXIciDRbmfTby_8mE4a5G7u-gqCEpg8hzwURRmj7bwxNcnfSH5J5IT9GOpOBuydsUk76s_6PGpDxInQC6EncqTbBrV_4MJ65SZtgIhzsFHNzWwUjuHQE_G-O60nft6NNjeYrcdjNrAGoWkkYrDthKZpCC8JLzeKMH_RNK3FSHjJFmu17W8KxssGiXh7jGM9wiCtX_kqIMVuhcfI8j8QPLFB-8qEoICICzTNrlF6TXgpCT8D3Y_qNVC_AravgaS4PBX6Udl5HO7WmQCDiVF2BhaJR6qc9B2kgwyqJ-IS5mPWqRnSIcxzulUxXasoLoyXkH4AmogHtbAvsU-PMZ4C757itPixkogTmBDGsPxR0jnAEQgv_q-uABtBDq3tpnGKXyUBWC7jDD9dHFjXRvG0SP7-z_f6Yep-RLNl7rXVEg3cJq_Qjv4XhNAT2-4WOuNNkGj04aknEl0LXYlKJqZmx4oxVomiSPq6uNGcFVUu87bMS61VpSvNipukWuRFxhJbc8oFLWlGBed5cRCi4tWNVaxohaA0Jxk1g7Tu4Nw8HMbQJTbGydTHLKNZ4mRrXPyaU6FenNJ26iLJqLMR4zcMLbp1ov3-28c5_YPkF9A2bt0oF627yPEGYZ7BegzWR6tgfylRSSfD2twR_rLYw83-bXTqjO-w371gGWbJFFzdI97j8ob4lfBrZ7Gf2oMaB8KvS0r7T3oP459GIeHXVVYk_Loq-zcAAP__srujKw">