From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Protected handlers & entry bodies Date: Sun, 18 Jan 2015 23:15:50 +0000 Organization: A noiseless patient Spider Message-ID: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="8878eaae66d49f7d529ec3c7abf78fb7"; logging-data="12264"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18nnH+sCE81H9LNVc4CKulLLRkw1xPABfM=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (darwin) Cancel-Lock: sha1:OHjomUQ7qqotgz5SaScPuFUlmaY= sha1:Y50FXa137l5qEprylmNoR9pc+eY= Xref: news.eternal-september.org comp.lang.ada:24602 Date: 2015-01-18T23:15:50+00:00 List-Id: This is for a Ravenscar RTS. In GNAT, if an protected entry's guard is opened by a protected procedure, the entry code is executed in the thread of control (task) that called the protected procedure. I haven't looked in detail at the normal RTS, but I suspect that after a protected procedure call each of the entries is serviced (the guard is evaluated, and if open the entry code is called). In Ravenscar, there's only one entry, so things are a bit simpler. The generated code appears to do exactly the same for protected procedure handlers, in which case the entry code is going to be executed in the thread of the ISR. This may well require restrictions on what can be done in the entry. Is this covered by C.3.1(17)?