Background: I'm working on porting an Ada project from Vxworks to a Linux platform. The project heavily relies on usage of Ada's dynamic task priorities.
I've done a couple experiments which have left me confused. Ada task priorities seem to have no effect on the underlying Linux priority/niceness. Two identical tasks with different priorities take equally long to complete, even when pinned to one CPU core.
Question: What are the semantics of Ada tasks on Linux? Why am I seeing no effect from setting task priorities?
I’m not up-to-date with Linux, but I remember that you could only change task priorities from the default if you ran the program as root. There may have been other conditions; getting dynamic priorities on Sparc Solaris was complicated.
The GNAT Reference Manual’s Specialized Needs Annexes section may claim that Annex D is fully implemented, and it’s certainly true that the code is present. However, 6 of the ACATS tests for Annex D fail on macOS, and the ACATS maintainer has said that the Annex D tests may not pass on non-specialised operating systems (sorry, can’t find the reference).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With