- Self-relocation
When computer programs execute upon a computer, their instructions are at the same time stored within the main memory of a computer. As it is necessary for the processor of the computer to retrieve these instructions in a timely and orderly fashion, it is necessary that these instructions be stored at a particular memory location, known by its address. In general, it is the case that the instructions of a program are stored in memory at fixed addresses. The instructions of the program do not move as the processor retrieves and executes them, in timely and orderly fashion.
Yet, it is possible to construct a computer program so that it does not stay at a fixed address in memory, even as it executes. This process is called self-relocation. As an extreme example, the
Apple Worm is a dynamic self-relocator.Self-relocation occurs when a program copies, in order, the code of its instructions from one sequence of locations to another sequence of locations within then main memory of a single computer, and then transfers processor control from the instructions found at the source locations of memory, to the instructions found at the destination locations of memory. As such, the data operated upon by the algorithm of the program is the sequence of octets (bytes) which define the program.
Wikimedia Foundation. 2010.