comp.lang.ada
 help / color / mirror / Atom feed
From: Niklas Holsti <niklas.holsti@tidorum.invalid>
Subject: Re: Interrupts handling in ADA
Date: Mon, 12 Dec 2011 11:12:08 +0200
Date: 2011-12-12T11:12:08+02:00	[thread overview]
Message-ID: <9kluo1FtlhU1@mid.individual.net> (raw)
In-Reply-To: <jc3rrs$27sq$1@news.ett.com.ua>

On 11-12-12 05:19 , anon@att.net wrote:
> --  Interrupts are not necessary. From you description a simple set of
> --  tasks is all that is needed.
> --
> --  This program outline uses three task to read three sockets and
> --  after pre-processing and verifing data (if needed) passes this
> --  data to a main task. The main task then can continue processing
> --  this data.

Just a small comment on a detail in the example:

>    task body Main is
...
>    begin
...
>          accept Acknowledge_1 ( Data : Unsigned_32 ) do
>            Task_1_Data := Data ;
>            -- process data from task 1
>          end Acknowledge_1 ;

The rendezvous between the Main task and task 1 continues until the "end 
Acknowledge_1". If the Main task processes the data from task 1 before 
the "end Acknowledge_1", as above, task 1 cannot do anything else during 
this processing. The program may be more responsive if the processing is 
done after the rendezvous, in this way:

         accept Acknowledge_1 ( Data : Unsigned_32 ) do
           Task_1_Data := Data ;
         end Acknowledge_1 ;
         -- process data from task 1

In this form, the call of Acknowledge_1 from task 1 returns before the 
processing, which means that task 1 can go on to do other things, while 
the Main task is processing the data in Task_1_Data.

-- 
Niklas Holsti
Tidorum Ltd
niklas holsti tidorum fi
       .      @       .



  reply	other threads:[~2011-12-12  9:10 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-10 20:43 Interrupts handling in ADA Ada @ BRL
2011-12-10 21:13 ` Vinzent Hoefler
2011-12-10 22:09 ` Niklas Holsti
2011-12-10 22:27 ` Simon Wright
2011-12-11 20:21   ` Martin Dowie
2011-12-13 13:51     ` Ada BRL
2011-12-13 23:18       ` Martin Dowie
2011-12-13 14:11     ` Niklas Holsti
2011-12-13 14:54       ` Simon Wright
2011-12-13 15:06         ` Ada BRL
2011-12-13 21:49           ` Niklas Holsti
2011-12-13 23:18       ` Martin Dowie
2011-12-13 12:47   ` Ada BRL
2011-12-13 15:07     ` Simon Wright
2011-12-13 15:23       ` Ada BRL
2011-12-13 18:14         ` Simon Wright
2011-12-13 18:56           ` Ada BRL
2011-12-13 19:56           ` Bill Findlay
2011-12-13 22:15         ` Niklas Holsti
2011-12-13 15:34       ` Simon Wright
2011-12-13 17:55         ` Ada BRL
2011-12-13 18:18           ` Dmitry A. Kazakov
2011-12-13 19:01             ` Ada BRL
2011-12-13 19:58               ` Dmitry A. Kazakov
2011-12-13 18:24           ` Simon Wright
2011-12-11  0:15 ` Jeffrey Carter
2011-12-13 12:53   ` Ada BRL
2011-12-11  9:23 ` Dmitry A. Kazakov
2011-12-13 13:11   ` Ada BRL
2011-12-13 14:04     ` Dmitry A. Kazakov
2011-12-13 14:51       ` Ada BRL
2011-12-13 15:02         ` Ada BRL
2011-12-13 15:39         ` Dmitry A. Kazakov
2011-12-13 18:51           ` Ada BRL
2011-12-13 19:51             ` Dmitry A. Kazakov
2011-12-13 23:32             ` georg bauhaus
2011-12-11 12:04 ` Georg Bauhaus
2011-12-13 14:08   ` Ada BRL
2011-12-12  3:19 ` anon
2011-12-12  9:12   ` Niklas Holsti [this message]
2011-12-13 13:36     ` Ada BRL
2011-12-12 15:23   ` björn lundin
2011-12-13 13:38     ` Ada BRL
2011-12-13 13:56       ` Ludovic Brenta
2011-12-13 14:10         ` Ada BRL
2011-12-13 13:31   ` Ada BRL
replies disabled

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