CS 541 Lecture -*- Outline -*- * economic impacts of different programming languages ** What is known According to Barry Boehm in "Software Engineering Economics" (Prentice-Hall, 1981)... *** Machine Oriented Language (MOL) vs. Higher Order Language (HOL) ------------------------------------------ ECONOMIC IMPACT OF PROGRAMMING LANGUAGES Source: Barry Boehm. Software Engineering Economics. Prentice-Hall, 1981. Using a HOL instead of a MOL gives a productivity improvement of 33% to 59%. So what takes 1.25 to 1.37 years with MOL, takes only 1 year with a HOL def: MOL is a machine-oriented language (e.g., assembly language) def: HOL is a higher-order language (e.g., FORTRAN or Pascal) ------------------------------------------ Why? Boehm and others find it takes same amount of effort to write 1 line of code in both a MOL and a HOL, but the HOL line does a lot more. Limitations: couldn't distinguish between Pascal and FORTRAN (HOLs) that is, on small project, there was not a major difference between Pascal and FORTRAN (Boehm, IEEE TSE, 1981). *** The big question Do other paradigms (OO, functional, logic) represent a similar step up in level? Can they be shown to improve productivity? ------------------------------------------ SOME CONJECTURES FOR EXPERIMENT Does 1 line of code take the same effort in any language? Does productivity increase proportional to how much shorter programs are in a given language? Does this increase hold for new paradigms, such as OO, functional, logic ? Does tool support make a difference? How does the effect of tool support compare with the effect of the language? ------------------------------------------ *** logical inferences programming language compilers etc cost money, so more expensive ones will lower profit (but not by much?) so commonly available and cheap languages better If want managers to understand the technical work, can't use too many languages so need general purpose language, and perhaps some specialized ones this might also argue for a general purpose language that can be extended (data abstraction, macros, OO features) and some special purpose libraries *** reuse ------------------------------------------ HOW REUSE AFFECTS ECONOMICS Profit from a module = profit from initial use - (programmer time cost + maintenance cost) + (N * (profit from reuse - cost of reuse)) What features promote reuse? ------------------------------------------ If a company can reuse software, then it will be better able to meet deadlines, produce lower cost, higher quality software so the language should aid reuse (this argues for languages with encapsulation, if not for OO features). *** tradeoffs ------------------------------------------ TRADEOFFS WHEN SELECTING A LANGUAGE Cost of compilers, tools, and training vs. productivity Costs in design and coding vs. costs in testing and maintenance ------------------------------------------ If happier employees are more productive, and happier employees cut costs for hiring and training, then the languages used should be ones the programmers enjoy (but we have precious little data on such preferences from programmers who have seen different kinds)