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=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,e7151167e0767ecc X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!news.glorb.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local1.nntp.dca.giganews.com!nntp.megapath.net!news.megapath.net.POSTED!not-for-mail NNTP-Posting-Date: Wed, 08 Sep 2004 20:11:36 -0500 From: "Randy Brukardt" Newsgroups: comp.lang.ada References: <8429999a.0408231027.2850e800@posting.google.com> <5ad0dd8a.0408302222.56282d6f@posting.google.com> <4135498c_1@news.tm.net.my> <5ad0dd8a.0409040738.3fff41b8@posting.google.com> <5ad0dd8a.0409060956.7fe744f6@posting.google.com> <5ad0dd8a.0409080110.1be46d74@posting.google.com> Subject: Re: Feasibility of using Ada in new development Date: Wed, 8 Sep 2004 20:12:30 -0500 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300 Message-ID: <16idnbx9y9hVMKLcRVn-gA@megapath.net> NNTP-Posting-Host: 64.32.209.38 X-Trace: sv3-dqluyre3o5HOpKmV7NRjA9zs1Vrdbj365IqEiDB9FXZmANK1noECuwzYi4VQzYhdhLDITZxbCLFYns5!B4O9+JTmJ7sHy4gNw7rQ2T144wfrdXD4IrqJwkuxG01uzNx3nWbrT44O7vbbPxhvTbmvv8+hGebl X-Complaints-To: abuse@megapath.net X-DMCA-Complaints-To: abuse@megapath.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.3.13 Xref: g2news1.google.com comp.lang.ada:3521 Date: 2004-09-08T20:12:30-05:00 List-Id: "Wojtek Narczynski" wrote in message news:5ad0dd8a.0409080110.1be46d74@posting.google.com... > Randy, > > > This is how tasking works in the Janus/Ada compiler. So, clearly there is > > something comparable available. But I wouldn't go so far as to call it high > > performance (it was designed to make tasking available on as many targets as > > possible). > > You mean you can put a task to sleep untill an IO descriptor is ready > for reading or writing? I don't know if you can even do that on Windows. I know that the API exists, but it was seriously broken the last time I looked. Perhaps its been fixed. In any case, the answer is no, there is no I/O support in our tasking (its the big flaw, which I why I said it wasn't high performance). But it doesn't use the OS threads. It would actually be fairly easy to build a special I/O library that could put a task to sleep (no threads here - only Ada :-). Just replace the implementation of Read and Write. Of course that wouldn't work for sockets, because sockets aren't I/O in Windows. The Claw sockets library supports various forms of socket waits, but experience has shown that (at least on Windows 2000), there is no performance to be gained there. Every one we tried was worse than the basic busy-wait a bunch of worker tasks implementation. (This was in the context of Ada Server, the web server that runs Adaic.com and the search engine for AdaIC, Ada-Auth.Org, and the ARM.) Randy.