If the regular context switches are triggered too fast, slow MCUs
will be able to spent little time on actually progressing in the
test. This will scale the IRQ rate with the CPU clock as a crude way
too keep load within limits.
Split out the regex that matches the output line into a dedicated
function (as it is used three times) and make it also accept nan and
inf as double values. Previously a nan didn't match and occasional
nans were not detected as a test failure.
Previously the test script expected runnable threads of the same
priority to be running in a specific order. But the only tool that is
guaranteed to enforce a specific order of runnable threads is assigning
them different priority levels.
This should fix a test failure in the nightlies.
Co-authored-by: Martine Lenders <mail@martine-lenders.eu>
- Perform the same computation over and over again. If the results
differ, context switches have an impact on the calculation (e.g.
when the FPU internally uses more bits than a float, but that bits
are not saved / restored on context switch)
- Give the three threads the names "t1", "t2", and "t3" and print them
on console, instead of the process ID. This makes interpretation of
the output easier, as the process IDs depend e.g. on whether a given
platforms requires an idle thread or not.
- Do not use the thread ID in the calculation, but the number at the
end of the thread name. This will result in the number printed only
depending on the precision of the (software) FPU and the printf()
implementation, and not on which threads are created in which order
(including the idle thread)
- Add a script to support running `make test`
Update tests/thread_float/tests/01-run.py
Co-authored-by: Alexandre Abadie <alexandre.abadie@inria.fr>
Add ATmega328P Xplained Mini board. The board is an official
development kit from MCHP based on the Arduino UNO, reduced
hardware, with a xplainedmini debugger and CDC ACM serial
converter.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
Added arduino-nano to BOARD_INSUFFICIENT_MEMORY/BOARD_BLACKLIST following suit
of how arduino-uno is marked, as arduino-nano is mostly an Uno in a different
form factor.