HOME

TheInfoList



OR:

In
computer science Computer science is the study of computation, automation, and information. Computer science spans theoretical disciplines (such as algorithms, theory of computation, information theory, and automation) to practical disciplines (includin ...
, link time refers to the period of time, during the creation of a computer program, in which a
linker Linker or linkers may refer to: Computing * Linker (computing), a computer program that takes one or more object files generated by a compiler or generated by an assembler and links them with libraries, generating an executable program or shar ...
is being applied to that program. Link time occurs after
compile time In computer science, compile time (or compile-time) describes the time window during which a computer program is compiled. The term is used as an adjective to describe concepts related to the context of program compilation, as opposed to concept ...
and before runtime (when a program is
executed Capital punishment, also known as the death penalty, is the State (polity), state-sanctioned practice of deliberately killing a person as a punishment for an actual or supposed crime, usually following an authorized, rule-governed process to ...
). It is common to speak of ''link time operations'' (the operations performed by a linker) or ''link time requirements'' (
programming language A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language. The description of a programming l ...
requirements that must be met by compiled
source code In computing, source code, or simply code, is any collection of code, with or without comment (computer programming), comments, written using a human-readable programming language, usually as plain text. The source code of a Computer program, p ...
for it to be successfully linked).


Link time operations

The operations performed at link time usually include fixing up the addresses of externally referenced objects and functions, various kinds of cross module checks (e.g. type checks on externally visible identifiers and in some languages instantiation of templates). Some optimizing compilers delay code generation until link time because it is here that information about a complete program is available to them. Resolving external variables in a program is also done at link time. The link-time optimization (LTO), when enabled, occurs at link time.


Link time requirements

The definition of a programming language may specify link time requirements that source code must meet to be successfully compiled (e.g. the maximum number of characters in an externally visible identifier that must be considered significant).


Exceptions

In some
programming language A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language. The description of a programming l ...
s it may be necessary for some compilation and linking to occur at runtime.


See also

* Program lifecycle phase *
Compile time In computer science, compile time (or compile-time) describes the time window during which a computer program is compiled. The term is used as an adjective to describe concepts related to the context of program compilation, as opposed to concept ...
*
Runtime (program lifecycle phase) In computer science, runtime, run time, or execution time is the final phase of a computer programs life cycle, in which the code is being executed on the computer's central processing unit (CPU) as machine code. In other words, "runtime" is t ...


References

{{DEFAULTSORT:Link Time Compiler construction