Design: Macro Assembler
- A macro processor functionally independent of the assembler, and the output of the macro processor will be a part of the input into the assembler.
- A macro processor, similar to any other assembler, scans, and processes statements. Often, the use of a separate macro processor for handling macro instructions leads to less efficient program translation because many functions duplicated by the assembler and macro processor.
- To overcome efficiency issues and avoid duplicate work by the assembler, the macro processor generally implemented within pass 1 of the assembler.
- The integration of macro processor and assembler often referred to as macro assembler. Such implementations will help in eliminating the overheads of creating intermediate files, thus improving the performance of integration by combining similar functions.
- Similarly, The advantages of a macro assembler are as follows:
It ensures that many functions need not implemented twice.
Results in fewer overheads because many functions combined and do not need to create intermediate (temporary) files.
It offers more flexibility in programming and allows the use of all assembler features in combination with macros.
- The disadvantages of a macro assembler are as follows:
o The resulting pass by combining macro processing and pass 1 of the assembler. May be too large and sometimes suffer from core memory problems.
o The combination of macro processor pass 0 and pass I may sometimes