This is an ESP-IDF app that links qf_math together with libfixmath, fr_math, and newlib libm (sinf, …), then runs the same numerical loops as make compare on your PC (compare/benchmark_core.c).
- Wall-clock numbers from
esp_timer_get_time()(microsecond resolution, FreeRTOS tick jitter still applies). - Accuracy checks versus double references (same grids as the host harness).
- Important: fixed-point peers are still exercised through float bridges here — same caveat as
compare/README.md§ Float vs fixed-point. For nativefix16_t/ radix-s32timings you would add separate loops later.
The UART log ends with Markdown between serial markers :::: DOC_TABLE_START :::: and :::: DOC_TABLE_END ::::. The checked-in MCU_BENCHMARK_SNAPSHOT_ESP32S3.md is refreshed from the LilyGO PlatformIO build via make mcu-benchmark-snapshot (same kernels).
-
ESP-IDF v5.x installed and sourced (
IDF_PATH,idf.pyonPATH). -
From the repository root, fetch compare dependencies (libfixmath + fr_math sources):
make compare-deps
That populates
build/compare/third_party/(gitignored).main/CMakeLists.txtpulls sources from there. -
Main task stack: each benchmark uses ~32 KiB of stack (
float inputs[8000]). This example setsCONFIG_ESP_MAIN_TASK_STACK_SIZE=65536insdkconfig.defaults. Do not shrink it without changingbenchmark_core.c.
cd examples/esp32s3_benchmark
idf.py set-target esp32s3
idf.py build flash monitorPower the board, connect USB-UART, then reset — the full report prints once over the serial console (same layout as the host benchmark_suite human mode).
LilyGO T-Display-S3 (USB + optional TFT): use examples/lilygo_t_display_s3_bench/ — PlatformIO board lilygo-t-display-s3, pio run -t upload -t monitor.
- CMake error — missing
fix16.c: runmake compare-depsfrom the repo root first. - Panics / stack overflow: confirm
CONFIG_ESP_MAIN_TASK_STACK_SIZEis at least 65536 (mergesdkconfig.defaultsinto yoursdkconfig, oridf.py menuconfig→ Main task stack size). - Wi-Fi / Bluetooth: left disabled by default; enable only if you need them — extra ISR load shifts timing.
| Path | Role |
|---|---|
main/app_main.c |
ESP timer adapter + bench_run_all / bench_print_human |
main/CMakeLists.txt |
Sources + include paths into repo root + build/compare/third_party/ |
CMakeLists.txt |
ESP-IDF project wrapper |
sdkconfig.defaults |
ESP32-S3 target hints, large main stack, -Os friendly defaults |