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-Thread: 103376,703c4f68db81387d X-Google-Thread: 115aec,703c4f68db81387d X-Google-Thread: f43e6,703c4f68db81387d X-Google-Attributes: gid103376,gid115aec,gidf43e6,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews.google.com!l41g2000cwc.googlegroups.com!not-for-mail From: "fabio de francesco" Newsgroups: comp.lang.ada,comp.realtime,comp.software-eng Subject: Re: Teaching new tricks to an old dog (C++ -->Ada) Date: 10 Mar 2005 20:00:20 -0800 Organization: http://groups.google.com Message-ID: <1110513620.359357.314400@l41g2000cwc.googlegroups.com> References: <4229bad9$0$1019$afc38c87@news.optusnet.com.au> <1110032222.447846.167060@g14g2000cwa.googlegroups.com> <871xau9nlh.fsf@insalien.org> <3SjWd.103128$Vf.3969241@news000.worldonline.dk> <87r7iu85lf.fsf@insalien.org> <1110052142.832650@athnrd02> <1110284070.410136.205090@o13g2000cwo.googlegroups.com> <395uqaF5rhu2mU1@individual.net> <112rs0bdr2aftdf@corp.supernews.com> <1inxxr988rxgg$.1w9dedak41k89.dlg@40tude.net> <112s1r0rf0o8nca@corp.supernews.com> <112sonip5v4dca6@corp.supernews.com> <112t3de6fu04f38@corp.supernews.com> <112u7undo5h2q0a@corp.supernews.com> NNTP-Posting-Host: 80.181.51.48 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1110513625 1352 127.0.0.1 (11 Mar 2005 04:00:25 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 11 Mar 2005 04:00:25 +0000 (UTC) In-Reply-To: User-Agent: G2/0.2 Complaints-To: groups-abuse@google.com Injection-Info: l41g2000cwc.googlegroups.com; posting-host=80.181.51.48; posting-account=Lp02jQ0AAABMd3TAghNf0TM2YBZqD_JE Xref: g2news1.google.com comp.lang.ada:9085 comp.realtime:1232 comp.software-eng:4800 Date: 2005-03-10T20:00:20-08:00 List-Id: Pascal Obry wrote: > I get: > > $ time matrix 100 > 270165 1061760 1453695 1856025 > > real 0m0.033s > user 0m0.010s > sys 0m0.020s > > $ time c_matrix 100 > 270165 1061760 1453695 1856025 > > real 0m0.033s > user 0m0.010s > sys 0m0.010s I think you made a big mistake by thinking you had equal results for matrix and c_matrix execution times. Don't look at "real" value, because it mostly depends on how much your computer is loaded while executing programs your're timing. That is the "real" time difference between start and end of program that is spent also in executing other tasks by your computer. You should only look at "user" and "sys" times that represent how much CPU time is spent for the particular program. "user" is time spent while executing in user address space, while "sys" is time spent while executing in kernel space on behalf of the program. Furthermore you'd better take times after a second execution in order to have both programs already in memory, so times are not affected by seeking disks and some othr operations. Ciao, fabio de francesco