Spent way too long fighting the 6 KB flash ceiling on a C6 running a WLED lightshow, so here's what actually helped. The big one was realizing the Arduino core drags in code you never touch. If your sketch never opens a Serial connection, the build tools still bundle the whole serial stack because the startup code name-checks it. Swapping to a leaner build where that reference is dropped saved me roughly 6 KB on a C6 and a bit more on an S3, which was exactly the headroom I needed for a bigger effect array.
Second tip, check your partition table. alot of boards ship with a default layout that reserves way more space for the app than a basic light controller needs. Trimming that down gave me another chunk without touching a line of code. Last thing, if you drive LEDs on a pin that doubles as the default serial recive pin, make sure the receiver actually lets go of it when Serial isn't in play. I chased a flicker on one strand for a week before realizing the pin was still being held. Worth a look if your build skips Serial entirely.