aboutsummaryrefslogtreecommitdiffstats
path: root/core/cpu_caps.h
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2020-12-31 16:47:12 -0800
committerChris Robinson <[email protected]>2020-12-31 16:47:12 -0800
commit20ef8bf390541339f068676f9d14061fe2f5e115 (patch)
tree6cca7aa12e11a6b5918fa3748391cb336d8d00bb /core/cpu_caps.h
parent002c5062964a598f8cdf53e6b3ed4836629c5048 (diff)
Move cpu_caps and fpu_ctrl to core
Diffstat (limited to 'core/cpu_caps.h')
-rw-r--r--core/cpu_caps.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/core/cpu_caps.h b/core/cpu_caps.h
new file mode 100644
index 00000000..ffd671d0
--- /dev/null
+++ b/core/cpu_caps.h
@@ -0,0 +1,26 @@
+#ifndef CORE_CPU_CAPS_H
+#define CORE_CPU_CAPS_H
+
+#include <string>
+
+#include "aloptional.h"
+
+
+extern int CPUCapFlags;
+enum {
+ CPU_CAP_SSE = 1<<0,
+ CPU_CAP_SSE2 = 1<<1,
+ CPU_CAP_SSE3 = 1<<2,
+ CPU_CAP_SSE4_1 = 1<<3,
+ CPU_CAP_NEON = 1<<4,
+};
+
+struct CPUInfo {
+ std::string mVendor;
+ std::string mName;
+ int mCaps{0};
+};
+
+al::optional<CPUInfo> GetCPUInfo();
+
+#endif /* CORE_CPU_CAPS_H */