From Wikipedia, the free encyclopedia - View original article
In computer science, a high-level programming language is a programming language with strong abstraction from the details of the computer. In comparison to low-level programming languages, it may use natural language elements, be easier to use, or may automate (or even hide entirely) significant areas of computing systems (e.g. memory management), making the process of developing a program simpler and more understandable relative to a lower-level language. The amount of abstraction provided defines how "high-level" a programming language is. Examples of high-level programming languages include Java, Lisp, R, Python, Visual Basic and Ruby.
The first high-level programming language designed for computers was Plankalkül, created by Konrad Zuse. However, it was not implemented in his time, and his original contributions were largely isolated from other developments (it influenced Heinz Rutishauser's language "Superplan").
"High-level language" refers to the higher level of abstraction from machine language. Rather than dealing with registers, memory addresses and call stacks, high-level languages deal with variables, arrays, objects, complex arithmetic or boolean expressions, subroutines and functions, loops, threads, locks, and other abstract computer science concepts, with a focus on usability over optimal program efficiency. Unlike low-level assembly languages, high-level languages have few, if any, language elements that translate directly into a machine's native opcodes. Other features, such as string handling routines, object-oriented language features, and file input/output, may also be present.
While high-level languages are intended to make complex programming simpler, low-level languages often produce more efficient code. Abstraction penalty is the border that prevents high-level programming techniques from being applied in situations where computational resources are limited. High-level programming exhibits features like more generic data structures, run-time interpretation, and intermediate code files; which often result in slower execution speed, higher memory consumption, and larger binary program size. For this reason, code which needs to run particularly quickly and efficiently may require the use of a lower-level language, even if a higher-level language would make the coding easier. In many cases, critical portions of a program mostly in a high-level language can be hand-coded in assembly language, leading to a much faster or more efficient optimised program.
However, with the growing complexity of modern microprocessor architectures, well-designed compilers for high-level languages frequently produce code comparable in efficiency to what most low-level programmers can produce by hand, and the higher abstraction may allow for more powerful techniques providing better overall results than their low-level counterparts in particular settings. High-level languages are designed independent of structure of a specific computer. This facilitates executing a program written in such a language on different computers.
The terms high-level and low-level are inherently relative. Some decades ago, the C language, and similar languages, were most often considered "high-level", as it supported concepts such as expression evaluation, parameterised recursive functions, and data types and structures, while assembly language was considered "low-level". Today, many programmers might refer to C as low-level, as it lacks a large runtime-system (no garbage collection, etc.), basically supports only scalar operations, and provides direct memory addressing. It, therefore, readily blends with assembly language and the machine level of CPUs and microcontrollers.
Assembly language may itself be regarded as a higher level (but often still one-to-one if used without macros) representation of machine code, as it supports concepts such as constants and (limited) expressions, sometimes even variables, procedures, and data structures. Machine code, in its turn, is inherently at a slightly higher level than the microcode or micro-operations used internally in many processors.
There are three general models of execution for modern high-level languages:
Note that languages are not strictly "interpreted" languages or "compiled" languages. Rather, language implementations use interpretation or compilation. For example, Algol 60 and Fortran have both been interpreted (even though they were more typically compiled). Similarly, Java shows the difficulty of trying to apply these labels to languages, rather than to implementations; Java is compiled to bytecode and the bytecode is subsequently executed by either interpretation (in a JVM) or compilation (typically with a just-in-time compiler such as HotSpot, again in a JVM). Moreover, compilation, trans-compiling, and interpretation are not strictly limited just a description of the compiler artifact (binary executable or IL assembly).
The Eiffel programming language (as implemented in the EiffelStudio IDE) uses both forms of compilation in a single development system (e.g. the IDE). While "Finalized" Eiffel code is trans-compiled to binary, "code-in-development" exists partially as either fully compiled machine code (complete with debugging and testing hooks into EiffelStudio) or as intermediate byte code, being interpreted by an Eiffel run-time (much like the JVM). Thus, for purposes of efficient development, the majority of an Eiffel project is compiled to binary, with small code changes "melted" out of the binary into IL "byte-code" in an Eiffel run-time virtual machine (EVM, if you will). As development moves along, the programmer will periodically "freeze" the small "melted" portions of code back into the "workbench" binary.