Re: Ada multi-threaded programs do not terminate under RedHat Linux
From: Patrice Freydiere (frett27_at_free.fr)
Date: 11/08/03
- Previous message: Nick Roberts: "Re: New limited range type?"
- In reply to: Ruben Stranders: "Ada multi-threaded programs do not terminate under RedHat Linux"
- Next in thread: Gerald Kasner: "Re: Ada multi-threaded programs do not terminate under RedHat Linux"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sat, 08 Nov 2003 22:36:41 +0100
it works fine on my Linux 9.0 mandrake box.
I use a Gnat 3.15, given on the gnat web site.
Patrice
ps: be careful, gnat has it's own gcc version that can interfere with
local gcc version if it's first in path.
On Fri, 07 Nov 2003 12:28:27 +0000, Ruben Stranders wrote:
> I'm a Ada newbie and I have to make a very simple program to
> demonstrate the use of multithreading in Ada. For that purpose, I
> created the following program.
>
> ============================
> procedure test is
> task type counter;
>
> task body counter is
> i : integer :=0;
> begin
> put_line("Start");
> while i < 10000 loop
> i := i + 1;
> end loop;
> put_line("Finish");
> end;
>
> task1 : counter;
>
> begin
> put_line("Test");
> end;
> ============================
>
> I've compiled it under RedHat Linux 9.0 with "gnatmake test.adb".
> Unfortunately, the resulting program doesn't terminate. Instead of the
> expected output:
>
> Starting
> Finished
> Test
>
> it only prints the first two lines. The body of the procedure "test"
> is never called. I've tried this with several other programs and on
> different machines (all with RedHat 9.0). Can anyone give me a
> pointer?
>
> Regards,
>
> Ruben
- Previous message: Nick Roberts: "Re: New limited range type?"
- In reply to: Ruben Stranders: "Ada multi-threaded programs do not terminate under RedHat Linux"
- Next in thread: Gerald Kasner: "Re: Ada multi-threaded programs do not terminate under RedHat Linux"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]