Ravenscar sounds really complicated, but it’s just a bunch of compiler directives to make the compiler enforce things. It also isn’t the end of Ada multitasking profiles either, as there’s also the newer Jorvik profile.
Ada’s killer feature is probably its built-in concurrency in general, but you have to get through it’s non-standard vocabulary.
Even without Ravenscar or Jorvik, “task” (thread) is a keyword and are scoped by default. “protected objects” are like monitors and can include guards and handle queueing automatically. Tasks and protected objects can have “entries” which are procedures in which you ask another concurrency type for something and when it’s ready it “accepts” that call (called a rendezvous).
Ravenscar sounds really complicated, but it’s just a bunch of compiler directives to make the compiler enforce things. It also isn’t the end of Ada multitasking profiles either, as there’s also the newer Jorvik profile.
Ada’s killer feature is probably its built-in concurrency in general, but you have to get through it’s non-standard vocabulary.
Even without Ravenscar or Jorvik, “task” (thread) is a keyword and are scoped by default. “protected objects” are like monitors and can include guards and handle queueing automatically. Tasks and protected objects can have “entries” which are procedures in which you ask another concurrency type for something and when it’s ready it “accepts” that call (called a rendezvous).
Worth noting “task” is implementation-dependent. It doesn’t have to map to a “thread”. AFAIR GCC/GNAT maps tasks to processes.
GCC/GNAT uses threads when there’s a OS. I have an Ada search program I wrote which I build with GNAT and it uses a thread pinned to each core.
Hmm, thank you. Maybe that was the case in the past. I need to dig deeper into this.