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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,63360011f8addace X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-07-15 09:09:19 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!news.freenet.de!not-for-mail From: Jan Prazak Subject: Re: time-slicing Date: Mon, 15 Jul 2002 18:10:33 -0100 Newsgroups: comp.lang.ada Message-ID: References: User-Agent: Pan/0.11.2 (Unix) Mime-Version: 1.0 Content-Type: text/plain; charset=iso885915 Content-Transfer-Encoding: 8bit X-Comment-To: "David C. Hoos" NNTP-Posting-Host: 213.7.143.109 X-Trace: 1026749357 news.freenet.de 8342 213.7.143.109 X-Complaints-To: abuse@freenet.de Xref: archiver1.google.com comp.lang.ada:27114 Date: 2002-07-15T18:10:33-01:00 List-Id: On Mon, 15 Jul 2002 12:07:10 -0100, David C. Hoos wrote: > Putting a delay statement (e.g. delay 0.02;) after each Put_Line > statement will cause the task to yield the CPU for at least the > specified time, thereby interleaving the tasks' execution. That sounds good, but it has not the right result. The output is ---- a b a b ---- because the commands are still not running simultaneously. Each command seems to wait until a running command (Put_Line) has finished. The tutorial says that there has to be a pragma, which enables time-slicing (and time-slicing is definitely disabled in gnat), when the output is not ---- ab ab ---- Maybe gnat doesn't even support time-slicing, but there is a command line switch and also a pragma (but as I have said, both unfortunately don't work). But actually I don't need this at the moment, it was just a question.