mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-19 20:30:58 +00:00
working for both neon32 and neon64 Update math_backend.cpp further sse simd additions avx2 float3 added added normalize_magnitude added divide fast to float3 may copy to float4 move static spheremesh to drawSphere (initialize on first use) so platform has a chance to load the math backend all float3 and float4 functions and isas completed all options of float3 and float4 functions in isas and math_c neon still to be done but that will be on mac. Update math_backend.cpp mac isa neon update added float3 restructured the classes to look more like the final version of the x86 classes linux required changes Update build-macos-clang.yml Update build-macos-clang.yml Revert "Update build-macos-clang.yml" This reverts commit29dfc567f4. Revert "Update build-macos-clang.yml" This reverts commit2abad2b4ca. Update CMakeLists.txt fix macs stupid build remove god awful rolling average from frame time tracker.... use intrinsic headers instead each isa implementation now uses a header for that isa's intrinsic functions these are then used in the impl files. This will make it easier for matrix functions when those are implemented. fixed comment saying 256 when it should be 512 for avx512 consolidated initializers for function tables Update neon_intrinsics.h fixes for some neon intrinsics no idea if this is the best way to do these but they work at least v_cross is especially messy at the moment we basically just do it as a c math function need to look into getting this done correctly
38 lines
725 B
C++
38 lines
725 B
C++
#pragma once
|
|
#ifndef _MATH_BACKEND_H_
|
|
#define _MATH_BACKEND_H_
|
|
|
|
#ifndef _MCONSTANTS_H_
|
|
#include "math/mConstants.h"
|
|
#endif
|
|
#ifndef _PLATFORMASSERT_H_
|
|
#include "platform/platformAssert.h"
|
|
#endif
|
|
#ifndef _FLOAT4_DISPATCH_H_
|
|
#include "math/public/float4_dispatch.h"
|
|
#endif
|
|
#ifndef _FLOAT3_DISPATCH_H_
|
|
#include "math/public/float3_dispatch.h"
|
|
#endif
|
|
#ifndef _MAT44_DISPATCH_H_
|
|
#include "math/public/mat44_dispatch.h"
|
|
#endif
|
|
|
|
namespace math_backend
|
|
{
|
|
enum class backend
|
|
{
|
|
scalar,
|
|
sse2,
|
|
sse41,
|
|
avx,
|
|
avx2,
|
|
neon
|
|
};
|
|
|
|
static backend g_backend = backend::scalar;
|
|
backend choose_backend(U32 cpu_flags);
|
|
void install_from_cpu_flags(uint32_t cpu_flags);
|
|
}
|
|
|
|
#endif // !_MATH_BACKEND_H_
|