mirror of https://github.com/stenzek/duckstation
GPU: Fix gsvector_nosimd -Wnontrivial-memcall warnings (#3704)
GSVector types are not trivially copyable, so passing their addresses
to memcpy/memmove/memset triggers warnings. Use the internal S32/F32
member arrays directly for these operations, and use fill() instead
of memset for array initialization.
Warning example before this commit:
```
common/gsvector_nosimd.h:1527:17: warning: first argument in call to 'memcpy' is a pointer to non-trivially copyable type 'GSVector4i' [-Wnontrivial-memcall]
1527 | std::memcpy(&ret, p, sizeof(ret.S32));
| ^
```
pull/3705/head
parent
19a165a5b1
commit
14ff42cd3b
Loading…
Reference in New Issue