rockbox/lib/rbcodec
Aidan MacDonald 7eeb4e4302 firmware: refactor CACHEALIGN_BITS/SIZE defines
Mostly motivated by PP needing CACHEALIGN_SIZE in linker
scripts, which can't include system.h, so move these to
cpu.h instead. Also gets rid of the default 32 byte line
size that was used if the target didn't define alignment
itself. RK24xx, DM320, and JZ4740 were missing this but
have been confirmed (from datasheets) to use 32-byte cache
lines.

Add checks to make sure the macros are appropriately
(un)defined based on the HAVE_CPU_CACHE_ALIGN define,
and make sure their values are consistent when they
are defined.

Disable HAVE_CPU_CACHE_ALIGN for hosted targets since it
arguably doesn't matter if there's a cache, if we aren't
responsible for cache maintenance.

A few files in rbcodec use CACHEALIGN_SIZE, but these
can be converted to MEM_ALIGN_SIZE, which is identical
to CACHEALIGN_SIZE if the latter is defined. On other
targets, it aligns to at least sizeof(intptr_t).

Change-Id: If8cf8f6ec327dc3732f4cd5022a858546b9e63d6
2026-03-06 14:49:00 +00:00
..
codecs firmware: refactor CACHEALIGN_BITS/SIZE defines 2026-03-06 14:49:00 +00:00
dsp dsp: Optimize fractional multiplication in audio processing 2025-12-08 16:14:06 +02:00
metadata metadata: vorbis: fix warning when building sim on aarch64 linux 2026-01-14 15:11:34 +01:00
test firmware: refactor CACHEALIGN_BITS/SIZE defines 2026-03-06 14:49:00 +00:00
platform.h firmware: refactor CACHEALIGN_BITS/SIZE defines 2026-03-06 14:49:00 +00:00
rbcodec.make rbcodec: Force use of -O2 for dsp code 2025-09-06 08:44:32 -04:00
rbcodecconfig-example.h Enable setting of global output samplerate on certain targets. 2013-07-06 04:22:04 +02:00
rbcodecplatform-unix.h libc: Add an implementation of strtol/strtoul and export it via plugins 2025-12-06 09:04:36 -05:00
SOURCES rbcodec dsp: Move dsp_sample_io_configure() to its own file 2022-12-22 17:20:14 -05:00