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,9c3a1871d2161925,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-07-03 08:57:34 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!nycmny1-snh1.gtei.net!cpk-news-hub1.bbnplanet.com!news.gtei.net!news-FFM2.ecrc.net!news.cesnet.cz!crax.cesnet.cz!news.felk.cvut.cz!not-for-mail From: Tomas Hlavaty Newsgroups: comp.lang.ada Subject: C/Ada performance comparison Date: Fri, 29 Jun 2001 16:19:22 +0200 Organization: Czech Technical University Message-ID: <3B3C8E6A.39361C75@labe.felk.cvut.cz> NNTP-Posting-Host: bela.felk.cvut.cz Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ns.felk.cvut.cz 993824095 56575 147.32.85.107 (29 Jun 2001 14:14:55 GMT) X-Complaints-To: usenet@ns.felk.cvut.cz NNTP-Posting-Date: Fri, 29 Jun 2001 14:14:55 +0000 (UTC) X-Mailer: Mozilla 4.72 [en] (X11; U; Linux 2.2.14-5.0 i686) X-Accept-Language: cs, en Xref: archiver1.google.com comp.lang.ada:9383 Date: 2001-06-29T16:19:22+02:00 List-Id: Hi, I have a question about the CPU load of Ada programs. I have a program reimplemented from C to Ada (Linux, GNAT) and now I've found the Ada program consumes about 7 times more CPU time than the C one. Is it common case or does it indicate an error in my Ada implementation (I'm quite new in Ada)? Is there any comparison/statistics on performance of C/Ada programs? I've tried to reduce the CPU time load of the Ada program and I found some surprising results. I compared rts-fsu and rts-native runtime environment and I found that rts-fsu is better (lower CPU load and only one running process per running program compared to rts-native). Why? I thougth rts-native should be better because it is more oriented towards the OS (gthreads...). Why is there so many processes when executing program compiled with rts-native? The Ada program has no tasks. And the last question: Is there any standard/common way how to implement synchronous I/O multiplexing like in C (select)? Thank you, Tomas -- Tomas Hlavaty mailto:hlavaty@labe.felk.cvut.cz Department of Cybernetics http://labe.felk.cvut.cz/~hlavaty Faculty of Electrical Engineering phone: (+420 2) 2435 7284 Czech Technical University