Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix: Yield after every execution of 'loop' if a loop delay of 0 is specified #38

Merged
merged 1 commit into from Oct 18, 2021

Conversation

aentinger
Copy link
Contributor

Otherwise we experience ressource starvation with the first started thread hogging the CPU all the time and the other threads will be never served.

… specified.

Otherwise we experience ressource starvation with the first started thread hogging the CPU all the time and the other threads will be never served.
@aentinger aentinger added the type: imperfection Perceived defect in any part of project label Oct 18, 2021
@aentinger aentinger self-assigned this Oct 18, 2021
@aentinger aentinger merged commit 1be8f61 into main Oct 18, 2021
@aentinger aentinger deleted the yield-if-no-delay branch October 18, 2021 12:34
@github-actions
Copy link

Memory usage change @ e050ccb

Board flash % RAM for global variables %
arduino:mbed_nano:nano33ble 🔺 0 - +64 0.0 - +0.01 0 - 0 0.0 - 0.0
arduino:mbed_nano:nanorp2040connect 0 - 0 0.0 - 0.0 0 - 0 0.0 - 0.0
arduino:mbed_portenta:envie_m4 🔺 0 - +64 0.0 - +0.01 0 - 0 0.0 - 0.0
arduino:mbed_portenta:envie_m7 🔺 0 - +64 0.0 - +0.01 0 - 0 0.0 - 0.0
Click for full report table
Board examples/Threading/Demo_Shared_Counter
flash
% examples/Threading/Demo_Shared_Counter
RAM for global variables
% examples/Threading/Demo_Source_Sink_Counter
flash
% examples/Threading/Demo_Source_Sink_Counter
RAM for global variables
% examples/Threading/Demo_Source_Sink_LED
flash
% examples/Threading/Demo_Source_Sink_LED
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_SPI
flash
% examples/Threadsafe_IO/Threadsafe_SPI
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_SPI_BusIO
flash
% examples/Threadsafe_IO/Threadsafe_SPI_BusIO
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Serial_GlobalPrefixSuffix
flash
% examples/Threadsafe_IO/Threadsafe_Serial_GlobalPrefixSuffix
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Serial_ProtocolWrapping
flash
% examples/Threadsafe_IO/Threadsafe_Serial_ProtocolWrapping
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Serial_Reader
flash
% examples/Threadsafe_IO/Threadsafe_Serial_Reader
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Serial_Writer
flash
% examples/Threadsafe_IO/Threadsafe_Serial_Writer
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Wire
flash
% examples/Threadsafe_IO/Threadsafe_Wire
RAM for global variables
% examples/Threadsafe_IO/Threadsafe_Wire_BusIO
flash
% examples/Threadsafe_IO/Threadsafe_Wire_BusIO
RAM for global variables
%
arduino:mbed_nano:nano33ble 0 0.0 0 0.0 64 0.01 0 0.0 64 0.01 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0
arduino:mbed_nano:nanorp2040connect 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0
arduino:mbed_portenta:envie_m4 64 0.01 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0
arduino:mbed_portenta:envie_m7 0 0.0 0 0.0 0 0.0 0 0.0 64 0.01 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0 0 0.0
Click for full report CSV
Board,examples/Threading/Demo_Shared_Counter<br>flash,%,examples/Threading/Demo_Shared_Counter<br>RAM for global variables,%,examples/Threading/Demo_Source_Sink_Counter<br>flash,%,examples/Threading/Demo_Source_Sink_Counter<br>RAM for global variables,%,examples/Threading/Demo_Source_Sink_LED<br>flash,%,examples/Threading/Demo_Source_Sink_LED<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_SPI<br>flash,%,examples/Threadsafe_IO/Threadsafe_SPI<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_SPI_BusIO<br>flash,%,examples/Threadsafe_IO/Threadsafe_SPI_BusIO<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Serial_GlobalPrefixSuffix<br>flash,%,examples/Threadsafe_IO/Threadsafe_Serial_GlobalPrefixSuffix<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Serial_ProtocolWrapping<br>flash,%,examples/Threadsafe_IO/Threadsafe_Serial_ProtocolWrapping<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Serial_Reader<br>flash,%,examples/Threadsafe_IO/Threadsafe_Serial_Reader<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Serial_Writer<br>flash,%,examples/Threadsafe_IO/Threadsafe_Serial_Writer<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Wire<br>flash,%,examples/Threadsafe_IO/Threadsafe_Wire<br>RAM for global variables,%,examples/Threadsafe_IO/Threadsafe_Wire_BusIO<br>flash,%,examples/Threadsafe_IO/Threadsafe_Wire_BusIO<br>RAM for global variables,%
arduino:mbed_nano:nano33ble,0,0.0,0,0.0,64,0.01,0,0.0,64,0.01,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0
arduino:mbed_nano:nanorp2040connect,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0
arduino:mbed_portenta:envie_m4,64,0.01,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0
arduino:mbed_portenta:envie_m7,0,0.0,0,0.0,0,0.0,0,0.0,64,0.01,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0

aentinger added a commit that referenced this pull request Nov 5, 2021
aentinger added a commit that referenced this pull request Nov 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: imperfection Perceived defect in any part of project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant