SLAU131Y October 2004 – June 2021
Start/Stop Macro Expansion Listing
.mlist
.mnolist
Two directives enable you to control the listing of macro and repeatable block expansions in the listing file:
The .mlist directive allows macro and .loop/.endloop block expansions in the listing file.
The .mnolist directive suppresses macro and .loop/.endloop block expansions in the listing file.
By default, the assembler behaves as if the .mlist directive had been specified.
See Chapter 7 for more information on macros and macro libraries. See the .loop/.break/.endloop topic for information on conditional blocks.
This example defines a macro named STR_3. The first time the macro is called, the macro expansion is listed (by default). The second time the macro is called, the macro expansion is not listed, because a .mnolist directive was assembled. The third time the macro is called, the macro expansion is again listed because a .mlist directive was assembled.
1 STR_3 .macro P1, P2, P3
2 .string ":p1:", ":p2:", ":p3:"
3 .endm
4
5 0000 STR_3 "as", "I", "am" ; Invoke STR_3 macro.
1 0000 003A .string ":p1:", ":p2:", ":p3:"
0001 0070
0002 0031
0003 003A
0004 003A
0005 0070
0006 0032
0007 003A
0008 003A
0009 0070
000a 0033
000b 003A
6 .mnolist ; Suppress expansion.
7 000c STR_3 "as", "I", "am" ; Invoke STR_3 macro.
8 .mlist ; Show macro expansion.
9 0018 STR_3 "as", "I", "am" ; Invoke STR_3 macro.
1 0018 003A .string ":p1:", ":p2:", ":p3:"
0019 0070
001a 0031
001b 003A
001c 003A
001d 0070
001e 0032
001f 003A
0020 003A
0021 0070
0022 0033
0023 003A