Skip to content

Add ESP32 board for the Test/Target SMP tests - #75

Open
sudeep-mohanty wants to merge 3 commits into
chinglee-iot:add-granular-lock-perf-comp-testsfrom
sudeep-mohanty:feat/esp32-perf-comp-board
Open

Add ESP32 board for the Test/Target SMP tests#75
sudeep-mohanty wants to merge 3 commits into
chinglee-iot:add-granular-lock-perf-comp-testsfrom
sudeep-mohanty:feat/esp32-perf-comp-board

Conversation

@sudeep-mohanty

Copy link
Copy Markdown

Adds an ESP-IDF board (Test/Target/boards/esp32) that builds and runs the SMP target tests, including the granular-lock performance-comparison tests, on the dual-core ESP32.

…tests

Adds an ESP-IDF integration of the Test/Target performance-comparison tests
(crit_speed, queue_speed, queue_contention, lock_contention_end_to_end) for the
dual-core ESP32. One test per binary, selected via -DPERF_TEST=<name>. Config is
driven from sdkconfig; a force-included board_test_config.h satisfies the
framework include-order contract, and test_setting_config.h supplies the ESP32
timing (CPU cycle counter) and printf hooks.
Portable regression test for the fix that stops the scheduler-suspension owner
core from being forced to yield. The victim pins to a core, suspends the
scheduler, raises a ready same-core helper above itself (marking its own core to
yield), then enters a task critical section - which spins forever in the
run-state-change helper without the fix. No ISR required. Wired into the ESP32
board runner.
…test

- CMakeLists auto-discovers the test source (<name>/<name>.c under tests/) and
  reads its entry function from testENTRY_FUNCTION_PROTOTYPE(...), so any test
  builds with -DTEST=<name> (legacy -DPERF_TEST= still works) - no per-test map.
- board_test_config.h: add an XT_NOP() fallback for tests that busy-loop with
  portNOP() (undeclared in a plain test TU on the Xtensa port).
- Runner task now matches the reference board (highest priority, no affinity);
  scheduler_owner_no_yield sets its own mid-range priority so it is independent
  of the runner priority.
- Add sdkconfig.no_multi_prio for tests needing configRUN_MULTIPLE_PRIORITIES=0,
  and document ESP-IDF config compatibility in the README.

Runs 10/12 functional SMP tests on ESP32; disable_multiple_priorities cannot
build (needs configUSE_CORE_AFFINITY=0, fixed to 1 on ESP-IDF) and
interrupt_wait_critical fails on a port critical-section-preemption difference.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant