| Issue |
52949
|
| Summary |
`__builtin_memcpy_inline` causes a front-end segfault with incorrect number of arguments / incorrect argument types
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
evanacox
|
Code that reproduces on trunk (or at least whatever Godbolt has as trunk):
```cpp
void f() {
__builtin_memcpy_inline();
}
```
It seems like there's just no error handling for that intrinsic. If the correct number of arguments are given but they're the wrong type, it segfaults as well:
```cpp
void f() {
__builtin_memcpy_inline(5, 5, 5);
}
```
```cpp
void f(void* a) {
__builtin_memcpy_inline(a, 5, 5);
}
```
The only misuse that actually has an error message is a size parameter that isn't a constant _expression_.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs