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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,718bd701b6b36346 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-08-14 01:58:38 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!news-FFM2.ecrc.net!news.iks-jena.de!lutz From: lutz@iks-jena.de (Lutz Donnerhacke) Newsgroups: comp.lang.ada Subject: Re: GNAT/Ada95 Streams Performance Issue Date: Wed, 14 Aug 2002 08:58:37 +0000 (UTC) Organization: IKS GmbH Jena Message-ID: References: <3D51ECC9.8020406@cogeco.ca> <3D585F63.6010205@otelco.net> <5ee5b646.0208130025.41805ea8@posting.google.com> <3D590D80.201@otelco.net> <5ee5b646.0208131311.735b9993@posting.google.com> NNTP-Posting-Host: taranis.iks-jena.de X-Trace: branwen.iks-jena.de 1029315517 8083 217.17.192.37 (14 Aug 2002 08:58:37 GMT) X-Complaints-To: usenet@iks-jena.de NNTP-Posting-Date: Wed, 14 Aug 2002 08:58:37 +0000 (UTC) User-Agent: slrn/0.9.6.3 (Linux) Xref: archiver1.google.com comp.lang.ada:28011 Date: 2002-08-14T08:58:37+00:00 List-Id: * Robert Dewar wrote: >That certainly makes more sense. The trouble is of course >that with Direct_IO you can't deal nicely with the last >partial block (you are also depending very much on impl >dependent choices in how Direct_IO works). > >Stream_IO should have the speed advantage without these >disadvantages. Sorry, don't take this to serious: ... function copy ( in_fd, out_fd : OS_File_T; offset : access OS_Off_T; count : OS_Size_T ) return OS_SSize_T; pragma Import(C, copy, "sendfile"); offset : aliased OS_Off_T := OS_Off_T'First; send : OS_SSize_T := copy (in_fd, out_fd, offset'Access, OS_Size_T'Last); begin if send = -1 then Put_Line ("Error ..."); else Put_Line ("Copied" & OS_SSize_T'Image (send) & " Bytes."); end if; end;