Topic summary

Macro instruction

Macro instruction

Extracted from the Wikipedia article Macro (computer science).

History

In the mid-1950s, when assembly language programming was the main way to program a computer, macro instructionfeatures were developed to reduce source code (by generating multiple assembly statements from each macro instruction) and to enforce coding conventions (e.g. specifying input/output commands in standard ways). A macro instruction embedded in the otherwise assembly source code would be processed by a macro compiler, a preprocessor to the assembler, to replace the macro with one or more assembly instructions. The resulting code, pure assembly, would be translated to machine code by the assembler.