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,dd6489250ee6bc95 X-Google-Attributes: gid103376,public Path: g2news1.google.com!news1.google.com!news.glorb.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local1.nntp.dca.giganews.com!nntp.comcast.com!news.comcast.com.POSTED!not-for-mail NNTP-Posting-Date: Sat, 19 Jun 2004 15:19:38 -0500 Date: Sat, 19 Jun 2004 16:19:38 -0400 From: "Robert I. Eachus" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Poor tasking performance References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 24.147.90.114 X-Trace: sv3-rm5JG+a2XnqsA4MIsBTfvX/HBrWSPyYiOWxCXmgGTa6nBpIA7oX6U+lX+TKiWU28U1S0ATXDz8DWmbI!fUdBGT/93HfDH1tFNXsYXRpSJEV/Ls0RsdxbpYxzdEX1+qrQBXced4YJo9EAzQ== X-Complaints-To: abuse@comcast.net X-DMCA-Complaints-To: dmca@comcast.net X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.1 Xref: g2news1.google.com comp.lang.ada:1699 Date: 2004-06-19T16:19:38-04:00 List-Id: Adrian Knoth wrote: > Is that normal? Only by adding one task which hangs in Get_Line > increases the load so much? > > Environment is Linux 2.6.7 with Debian gcc-3.3 (unstable). First, let me say you are lucky to get working results with that combination. Most Ada users have skipped gcc-3.3. (I haven't switched from 3.15p to gcc-3.4 yet, but that is my intent at some point.) But I don't think that your question can be answered in an Ada context. This is definitely an area where the underlying OS implementation of reading from the console is going to account for most of the overhead. If you are using Get_Immediate in Text_IO, you could switch to line at a time reading and see if that helps. But I suspect that it won't--the OS needs to poll the UART that buffers keyboard input at a certain rate to avoid losing characters. With a different keyboard, or keyboard driver, you might get very different results. -- Robert I. Eachus "Reason and experience both forbid us to expect that national morality can prevail in exclusion of religious principles." -- George Washington