mirror of https://github.com/zeldaret/botw.git
Havok: Fix matching issue in hkVector4f::set
Annoyingly, v = {x, y, z, w} and vcombine_f32({x, y}, {z, w} lead to different codegen. It is unclear why Havok decided to split the load in two parts.
This commit is contained in:
parent
9ee731c40c
commit
afabdf7132
|
@ -22,10 +22,13 @@ inline hkVector4f& hkVector4f::operator=(hkVector4fParameter other) {
|
|||
}
|
||||
|
||||
inline void hkVector4f::set(hkFloat32 x, hkFloat32 y, hkFloat32 z, hkFloat32 w) {
|
||||
v[0] = x;
|
||||
v[1] = y;
|
||||
v[2] = z;
|
||||
v[3] = w;
|
||||
#ifdef HK_VECTOR4F_AARCH64_NEON
|
||||
// Annoyingly, v = {x, y, z, w} and vcombine_f32({x, y}, {z, w} lead to different codegen.
|
||||
// It is unclear why Havok decided to split the load in two parts.
|
||||
v = vcombine_f32(float32x2_t{x, y}, float32x2_t{z, w});
|
||||
#else
|
||||
v = {x, y, z, w};
|
||||
#endif
|
||||
}
|
||||
|
||||
inline void hkVector4f::setAll(hkReal x) {
|
||||
|
|
Loading…
Reference in New Issue