User loginNavigation |
Why determinism matters in language design.In the recent set of discussion on functions vs procedures a reference was made to the ADA language design choice neither to ban side effects in functions nor specify the order of evaluation of expressions. So let me explain why this upsets me. Thus thanks to our indecision coupled with human incompetence of the average programmer.. if you run a large program on a different compiler, or a different version of the same compiler, or with different optimization settings.... expect different results. If you look at large modern commercial software systems... a large chunk of the cost (even worse schedule time) is in testing and retesting. Mostly our test department goes hunting in areas where we have introduced change. However, bad language design choices as made by the Ada design team add to the need for us to say to the test department... "Ah, we've had to change X (where X is one of that list above), so anything is possible. Sorry, you have to retest everything." This can easily result in the vast proportion of the cost of a release being in the test phase. Which can be devastating to the release date schedule, as they are _always_ on the critical path. (Final test comes after everything else is done and dusted) Determinism SHOULD feature highly as a design criteria for language designers. Yes, programmers shouldn't code bugs.... but get real. In very large industrial systems there are hundreds even tens of thousands of bugs in shipped systems. Thus it is important that wherever possible, even if the program is just plain rong, different compilers, compiler versions, optimizer settings and memory layout, wherever possible produce the _same_ tested and accepted wrong behaviour. Obviously it will not always be possible. Obviously wherever possible defects should be prevented from being written, defects should be detected and fixed. But simple language design choices that "prematurely optimize" by destroying determinism cost millions. Determinism matters. By John Carter at 2009-08-19 22:55 | LtU Forum | previous forum topic | next forum topic | other blogs | 7081 reads
|
Browse archives
Active forum topics |
Recent comments
22 weeks 6 days ago
22 weeks 6 days ago
22 weeks 6 days ago
45 weeks 19 hours ago
49 weeks 2 days ago
50 weeks 6 days ago
50 weeks 6 days ago
1 year 1 week ago
1 year 6 weeks ago
1 year 6 weeks ago