Path: csiph.com!goblin3!goblin.stu.neva.ru!news.misty.com!news.iecc.com!.POSTED.news.iecc.com!nerds-end From: "Robin Vowels" Newsgroups: comp.compilers Subject: Re: Optimization techniques and runtime checks Date: Sat, 11 May 2019 19:26:06 +1000 Organization: Compilers Central Lines: 32 Sender: news@iecc.com Approved: comp.compilers@iecc.com Message-ID: <19-05-079@comp.compilers> References: <72d208c9-169f-155c-5e73-9ca74f78e390@gkc.org.uk> <19-04-021@comp.compilers> <19-04-023@comp.compilers> <19-04-037@comp.compilers> <19-04-046@comp.compilers> <19-05-052@comp.compilers> <19-05-059@comp.compilers> <19-05-064@comp.compilers> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset="utf-8"; reply-type=original Content-Transfer-Encoding: 8bit Injection-Info: gal.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="86837"; mail-complaints-to="abuse@iecc.com" Keywords: tools, comment Posted-Date: 11 May 2019 11:16:14 EDT X-submission-address: compilers@iecc.com X-moderator-address: compilers-request@iecc.com X-FAQ-and-archives: http://compilers.iecc.com Xref: csiph.com comp.compilers:2314 From: "David Brown" Sent: Wednesday, May 08, 2019 6:31 PM > I have many times noted that C is often a poor choice of language. > There was a time when it was the best, or only, language suitable for a > wide range of uses. That not so. C was never the best (ior only) language. PL/I and Ada are probably in that category. PLI has been used for system programming as well as general purpose programming. > This is no longer the case. I personally use it > for small-systems embedded programming, and the runtime efficiency /is/ > important. But for PC programming, I use mostly Python (I used to use > Delphi more). Pick a language that makes sense for the job, and gives > the trade-offs that suit your needs. > > And often there is no way to handle run-time errors sensibly anyway. > You don't want your car brakes to give you a message "Your braking > system has encountered an integer overflow. Please report this error to > your car dealer". You want the brake software developers to be > /absolutely/ sure that overflows can't happen - and then there is no > point in run-time checks. Wishful thinking. While the code in a program can avoid a hardware overflow (through appropriate programming), in the event that an overflow occurs, the program still needs to tell the outside world that an overflow occurred. [I think you will find that the PL/I that people have used for system programming is pretty stripped down, like Intel's PL/M and IBM's PL/S. -John]