From 09eaf084d06afc4bb71cbc93bdb2d05adac8d076 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Wed, 5 Feb 2025 10:55:10 -0600 Subject: [PATCH] Remove unused float16 type --- Common/Math/math_util.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/Common/Math/math_util.h b/Common/Math/math_util.h index 033e48ba90..4f4d30c982 100644 --- a/Common/Math/math_util.h +++ b/Common/Math/math_util.h @@ -7,15 +7,6 @@ #include #include -typedef unsigned short float16; - -inline float Float16ToFloat(float16 ix) { - uint32_t extended = ix; - float x; - memcpy(&x, &extended, sizeof(float)); - return x; -} - inline bool isPowerOf2(int n) { return n == 1 || (n & (n - 1)) == 0; } @@ -36,6 +27,7 @@ inline uint32_t RoundUpToPowerOf2(uint32_t v, uint32_t power) { return (v + power - 1) & ~(power - 1); } +// TODO: this should just use a bitscan. inline uint32_t log2i(uint32_t val) { unsigned int ret = -1; while (val != 0) {