many things, cosmo build!

This commit is contained in:
veclavtlica
2026-10-12 21:12:47 +03:00
parent ba4131abbf
commit 8d2bb5575e
29 changed files with 699 additions and 312 deletions
+3 -5
View File
@@ -23,8 +23,6 @@ typedef int32_t com_fix_t;
extern const uint16_t com_fix_sin_lut[128];
void com_fix_print(com_fix_t a);
void com_fix_run_tests(void);
void com_fix_run_bench(void);
@@ -32,9 +30,9 @@ static inline com_fix_t com_fix_add(com_fix_t a, com_fix_t b) { return a + b; }
static inline com_fix_t com_fix_sub(com_fix_t a, com_fix_t b) { return a - b; }
static inline com_fix_t com_fix_int(com_fix_t a) {
return a >> COM_FIX_FRACBITS;
}
static inline int16_t com_fix_int(com_fix_t a) { return a >> COM_FIX_FRACBITS; }
static inline uint16_t com_fix_frac(com_fix_t a) { return a & 0xFFFF; }
static inline com_fix_t com_fix_mul(com_fix_t a, com_fix_t b) {
return (com_fix_t)(((int64_t)a * (int64_t)b) >> COM_FIX_FRACBITS);