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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,442eb9212004f30 X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!news.glorb.com!wn13feed!worldnet.att.net!bgtnsc04-news.ops.worldnet.att.net.POSTED!53ab2750!not-for-mail Newsgroups: comp.lang.ada From: anon@anon.org (anon) Subject: Re: Problem using Ada.Text_IO.Modular_IO Reply-To: no to spamers (No@email.given.org) References: <4eab7055-df3d-4d56-87da-8248829da1da@26g2000hsk.googlegroups.com> <867127d8-3b21-40dd-bb76-f19cd349b21e@26g2000hsk.googlegroups.com> <4%Pdk.112546$102.54800@bgtnsc05-news.ops.worldnet.att.net> <4878820c$0$27451$9b4e6d93@newsspool4.arcor-online.net> X-Newsreader: IBM NewsReader/2 2.0 Message-ID: Date: Sun, 13 Jul 2008 00:51:44 GMT NNTP-Posting-Host: 12.65.42.101 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc04-news.ops.worldnet.att.net 1215910304 12.65.42.101 (Sun, 13 Jul 2008 00:51:44 GMT) NNTP-Posting-Date: Sun, 13 Jul 2008 00:51:44 GMT Organization: AT&T Worldnet Xref: g2news1.google.com comp.lang.ada:1131 Date: 2008-07-13T00:51:44+00:00 List-Id: Back when there were widely use hardware with different word sizes you would need to define the type. But before Microsoft, the computer world decides to use base 2 in the following formats 8/16/32/64/128/256 with each having different problems of access time based on the cpu and data sizes.. In other words a 32-bit system has a faster time accessing a 32-bit word than accessing a 8-bit word. And has to use extra routines to simulate a 5-bit words instruction or data size. Plus, when a programmer defines their own type in Ada, Ada adds extra set of routines that are not based in hardware checks but software, which slows a program down. And when you are using sometime like "mod 2**64" which is pre-define as Unsigned_64 which can be hardware check (because it is a full 64-bit word) why would any programmer add a user defined type that would slow their program down for no reason other than to waste time, both in programming/debugging and execution time. And as any boss will tell you time is money and money is the bottom line. Or in the Gaming world the more time it take the more likely player will lose the game and the player will lose interest in the game, and stop buying the programmers game. etc. So, TIME is still a big factor to programmers. And as for defining types and let the compiler add the vendors verification routines, should ONLY happen in the classroom. If programmere define a type then they should define how and where the verification will take place not the compiler. Aka using Ravenscar type of programming. But for most programmers it seams, Ravenscar type of programmere is just too hard to use. But once you start using Ravenscar you will never go back to the old ways. In <4878820c$0$27451$9b4e6d93@newsspool4.arcor-online.net>, Georg Bauhaus writes: >anon wrote: >> But like the rest you miss the point. "KNOW and USE your Ada System and >> stop wasting time reventing types or routines!" And USE as much of the >> system as you can or it may not be there tomorrow, when you really need it!" > >The other point is that using an Ada system well means to know >the Ada fundamental type system. Start thinking about the types >that your program needs. Most of the time this means, avoid >the predefined "vague" types, they are overly inclusive types, >not specific to the task at hand and hence convey little meaning. >You get the same speed if you define your own types, (re)using >the Ada fundamental type system. > >If interfacing to hardware, or to other languages, use types from >the Interface hierarchy. > >-- >Georg Bauhaus >Y A Time Drain http://www.9toX.de