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,6a8952cbe009f3ed X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit X-Received: by 10.66.77.231 with SMTP id v7mr398413paw.35.1359024938327; Thu, 24 Jan 2013 02:55:38 -0800 (PST) X-Received: by 10.50.47.134 with SMTP id d6mr377573ign.0.1359024938284; Thu, 24 Jan 2013 02:55:38 -0800 (PST) Path: 6ni14228pbd.1!nntp.google.com!f6no13689352pbd.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 24 Jan 2013 02:55:37 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=130.240.232.139; posting-account=Rr9I-QoAAACS-nOzpA-mGxtAlZ46Nb6I NNTP-Posting-Host: 130.240.232.139 References: <4905b963-0036-4129-8050-fb26ef0154d6@googlegroups.com> <32314026-23ae-45b8-a4c5-e589e7d79de2@googlegroups.com> <3l3jf85ae05qgsl2l0avomebmg2ogl17rq@invalid.netcom.com> <13febf5c-4e3c-4275-8ff4-0a3a9e885d31@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <796d0b70-fce0-454c-aeb0-3031b5eba200@googlegroups.com> Subject: Re: Numerical calculations: Why not use fixed point types for everything? From: Ada novice Injection-Date: Thu, 24 Jan 2013 10:55:38 +0000 Content-Type: text/plain; charset=ISO-8859-1 Date: 2013-01-24T02:55:37-08:00 List-Id: On Saturday, January 19, 2013 7:26:25 AM UTC+1, Jeffrey Carter wrote > > > jrcarter@jrcarter-gateway-1:~/Code$ ./sum > > Float took 0.007979000 > > Fixed took 0.008180000 > > jrcarter@jrcarter-gateway-1:~/Code$ ./sum > > Float took 0.007971000 > > Fixed took 0.008278000 > > jrcarter@jrcarter-gateway-1:~/Code$ ./sum > > Float took 0.007979000 > > Fixed took 0.008403000 > > > > It seems that floating-point operations are slightly faster than fixed point on > > a (sort of) modern processor (AMD Athlon II M300). > > > > The code: > > > > with Ada.Real_Time; > > with Ada.Text_IO; > > > > with PragmARC.Universal_Random; > > Hi, When I run your code with GNAT GPL 2011, I get the error message: "file pragmARC.ads" not found. Thanks. YC