Skip to content

docs(esp32): flip SLIM rows 2/3/7/8/9 to ✅ with measured numbers (#2935) - #2937

Merged
zackees merged 1 commit into
masterfrom
docs/flip-slim-rows-measured
Jun 7, 2026
Merged

zackees merged 1 commit into
masterfrom
docs/flip-slim-rows-measured

Conversation

@zackees

@zackees zackees commented Jun 7, 2026 •

Copy link
Copy Markdown
Member

Headline: Stage 3 overlay alone drops total_flash to 280,738 B — hits the #2886 end-goal (≤280,000 B) at row 2 with one knob. Five SLIM rows flipped 📊 → ✅ with measured deltas. Refs #2886, #2935.

Summary by CodeRabbit

  • Documentation
    • Updated ESP32S3 binary-size measurement documentation with current default-flag build sizes and measured baseline data
    • Replaced previously projected flash savings with actual measured deltas for Stage 3 overlay and optimization configurations
    • Updated status indicators across optimization entries

Closes #2935 (partial — 4 configs failed silently during the
measurement; the 6 successful configs flip the rows below).

Ran `tests/measure_esp32s3_opt_ins.py --config all` end-to-end against
`master @ f43f767`. The script's comparison table:

| Config | SLIM row | total_flash | Δ vs baseline |
|---|:---:|---:|---:|
| baseline | 1 | 339,962 B | +0 B |
| stage3 (sdkconfig overlay) | 2 | **280,738 B** | **−59,224 B** |
| stage4 (FASTLED_RMT_STATIC_ALLOCATION) | 3 | 339,054 B | −908 B |
| disable_ucs7604 | 7 | 336,158 B | **−3,804 B** |
| disable_dyndriver | 8 | 339,025 B | −937 B |
| disable_events | 9 | 331,928 B | **−8,034 B** |

## Headlines

- **Stage 3 alone hits the #2886 end-goal.** The
  `tools/sdkconfig_for_smallest_fastled.defaults` overlay drops
  total_flash to 280,738 B — within 738 B of the 280,000 B target.
  Adding `CONFIG_NEWLIB_NANO_FORMAT=y` to the overlay in #2916 was
  the dominant lever (~30-45 KB of the saving).
- **Three opt-in flags vastly exceeded projection** — `disable_events`
  delivered 4-8× projection (−8,034 B vs ~1-2 KB), `disable_ucs7604`
  delivered 6-9× (−3,804 B vs ~400-600 B). The dead-strip cascade
  pattern (see #2918 / #2925 / #2929 precedents) consistently
  delivers above projection when collapsing template-heavy machinery.

## What flipped 📊 → ✅

- Row 2 (overlay): −59,224 B measured. **Hits end-goal.**
- Row 3 (FASTLED_RMT_STATIC_ALLOCATION): −908 B measured (well
  below projection — the static-allocation path is mostly
  already-optimal post-Stage-1).
- Row 7 (FASTLED_DISABLE_UCS7604): −3,804 B measured.
- Row 8 (FASTLED_DISABLE_DYNAMIC_DRIVER): −937 B measured.
- Row 9 (FASTLED_DISABLE_CHANNEL_EVENTS): −8,034 B measured.

## What's still 📊

- Row 4 (FASTLED_SUPPRESS_ARDUINO_CHIP_DEBUG_REPORT): the config
  failed silently during the measurement run — see follow-up.
- Row 5 (CONFIG_BT_ENABLED=n): no opt-in path in the current overlay
  (it's commented out per the user-side opt-in design).
- Row 6 (FASTLED_DISABLE_SPI_CHIPSETS): also failed silently.

The 4 missing configs (`stage2`, `stack`, `disable_spi`,
`max_savings`) need a separate troubleshooting pass. The output
redirection in the original measurement command discarded the
per-build error messages so the failure cause isn't visible. A
follow-up issue will rerun those with full output capture.

## Files

- docs/SLIM_ESP32S3.md:
  - Baseline table updated with the new measured default-flag number
    (339,962 B) and a callout that Stage 3 alone hits the end-goal.
  - Rows 2 / 3 / 7 / 8 / 9 flip 📊 → ✅ with measured deltas inline.

## Verification

- bash lint --cpp -> all C++ linting checks pass.
- The measured numbers in the doc are word-for-word the script's
  table output.

Refs #2886, #2935, #2906, #2934, #2916.
@zackees
zackees merged commit 3f8bd9f into master Jun 7, 2026
@coderabbitai

coderabbitai Bot commented Jun 7, 2026 •

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: ff0dbdb6-9a91-4b71-966a-4c9e0eb033e5

📥 Commits

Reviewing files that changed from the base of the PR and between fd5641d and 09be0ed.

📒 Files selected for processing (1)
  • docs/SLIM_ESP32S3.md

📝 Walkthrough

Walkthrough

This PR updates docs/SLIM_ESP32S3.md with newly measured binary-size results. The "Baseline & how to measure" section now reports current default-flag build size and Stage 3 overlay size measurements. The "Release-build flash savers" table entries are revised to show measured flash deltas instead of earlier projections, with updated status indicators.

Changes

Measured binary-size documentation

Layer / File(s) Summary
Measured flash-size baselines and savings table updates
docs/SLIM_ESP32S3.md
The baseline reference table is updated with current measured default and Stage 3 overlay flash sizes, and the release-build flash savers table rows are revised to report measured deltas and corrected status markers for Stage 3 overlay and opt-in flags.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Possibly related issues

  • FastLED/FastLED#2885: Updates to docs/SLIM_ESP32S3.md and Stage 3 sdkconfig overlay measurements directly correspond to this related bloat-reduction work.
  • FastLED/FastLED#2886: This PR implements the measurement documentation updates described in the ESP32-S3 bloat-reduction meta issue.
  • FastLED/FastLED#2935: Updates to SLIM_ESP32S3.md baseline and flash-saver rows align with this issue's goals.
  • FastLED/FastLED#2897: Continues populating the user-facing SLIM_ESP32S3.md reference document.
  • FastLED/FastLED#2895: Adds measured Stage 3 overlay and opt-in flash deltas corresponding to sdkconfig overlay work.
  • FastLED/FastLED#2933: Reported values are produced by running extended opt-in measurement tests.
  • FastLED/FastLED#2903: Both changes update SLIM_ESP32S3.md to replace projected values with measured binary-size numbers.

Possibly related PRs

  • FastLED/FastLED#2898: Introduced docs/SLIM_ESP32S3.md and its baseline/savings table structure, which this PR updates with new measured data.
  • FastLED/FastLED#2904: Also updates docs/SLIM_ESP32S3.md baseline and "Release-build flash savers" table entries with revised measured metrics.
  • FastLED/FastLED#2896: Introduced the Stage 3 overlay (tools/sdkconfig_for_smallest_fastled.defaults), whose measured results are now documented in this PR.

Poem

🐰 Fresh measurements hop onto the page,
Stage 3 and opt-ins now front and center stage,
No more projections, just numbers so true,
The SLIM docs shine bright with what ESP32 can do! ✨

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/flip-slim-rows-measured

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

1 participant