comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: ANN: Cortex GNAT RTS 2018-07-15
Date: Sat, 28 Jul 2018 12:18:48 +0100
Date: 2018-07-28T12:18:48+01:00	[thread overview]
Message-ID: <ly7elfr4kn.fsf@pushface.org> (raw)
In-Reply-To: 87in50e71g.fsf@nightsong.com

Paul Rubin <no.email@nospam.invalid> writes:

> Simon Wright <simon@pushface.org> writes:
>> I agree that a considerable chunk of FreeRTOS could probably be
>> replaced by straightforward Ada code, but that'd be someone else's
>> project!
>
> Thanks.  I wasn't suggesting that you rewrite FreeRTOS, but rather, I
> was just wondering if there were technical obstacles to doing such
> such machine-level stuff in Ada.

Not really: you are coming at things from underneath, so need a
different mindset. The tricky part is organising context swaps, I
think. GCC supports in-line assembler, so for instance you can tell
whether you're in an ISR on an ARM processor (v6, v7 anyway) by
an MRS instruction, and I have no doubt you can do the same for context
swaps; but it's very architecture-specific.

>> The RTOS part of AdaCore's embedded Ravenscar RTOSs (s-bb*.ad?) is
>> about 5500 lines (1250 semicolons) of Ada.
>
> Fabien also Chouteau mentioned this.  Does it do mostly the same stuff
> as FreeRTOS?  I had thought Ravenscar was deliberately very limited.

Ravenscar limits what tasks/protected objects can do (for example, tasks
must be declared at library level; tasks mustn't exit; no task entries;
POs can only have one entry) which (a) makes it possible to argue about
correctness and (b) greatly reduces the complexity of the RTS. AdaCore's
RTS does considerably more than I've implemented in Cortex GNAT RTS,
e.g. multiprocessing - which I think FreeRTOS would support - but it's
still Ravenscar tasking.


  reply	other threads:[~2018-07-28 11:18 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-15 19:41 ANN: Cortex GNAT RTS 2018-07-15 Simon Wright
2018-07-15 21:53 ` Paul Rubin
2018-07-16  8:53   ` fabien.chouteau
2018-07-16 11:56   ` Simon Wright
2018-07-27  9:07     ` Paul Rubin
2018-07-27 10:13       ` fabien.chouteau
2018-07-27 20:20       ` Simon Wright
2018-07-27 20:51         ` Paul Rubin
2018-07-28 11:18           ` Simon Wright [this message]
2018-07-16 14:56   ` Simon Wright
2018-07-17  2:14     ` Paul Rubin
2018-07-17  8:27       ` fabien.chouteau
2018-07-17  9:43         ` Paul Rubin
2018-07-17 10:21           ` fabien.chouteau
2018-07-17 13:14       ` Simon Wright
2018-07-17 19:46         ` Paul Rubin
2018-07-18  0:59           ` Paul Rubin
2018-07-18  7:27           ` Dmitry A. Kazakov
2018-07-18  8:29             ` Paul Rubin
2018-07-18 11:31         ` Tero Koskinen
2018-07-18 21:52           ` Paul Rubin
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox