blob: 13a776a457c4711b3057459a5b656ea292d8b15e [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001SYNOPSIS
Zesstra715ec202025-07-09 22:18:31 +02002 string * last_instructions(int length, int verbose)
MG Mud User88f12472016-06-24 23:31:02 +02003
Zesstra715ec202025-07-09 22:18:31 +02004DESCRIPTION
5 Returns an array showing the 'length' last executed
6 instructions in disassembled form. If 'verbose' is non-zero
7 (the default), line number information are also included.
8 Each string is built as this:
MG Mud User88f12472016-06-24 23:31:02 +02009
Zesstra715ec202025-07-09 22:18:31 +020010 Opcode-Address: Opcode Operand Mnemonic (Stackdepth) Linenumber
MG Mud User88f12472016-06-24 23:31:02 +020011
Zesstra715ec202025-07-09 22:18:31 +020012 The Stackdepth information consists of two numbers <rel>:<abs>:
13 <rel> is the relative stack usage in this function, <abs> is the
14 absolute stack usage.
MG Mud User88f12472016-06-24 23:31:02 +020015
Zesstra715ec202025-07-09 22:18:31 +020016 The linenumber information is appended if requested and a new
17 source line is reached. Also, calls between objects produce a
MG Mud User88f12472016-06-24 23:31:02 +020018
Zesstra715ec202025-07-09 22:18:31 +020019 Objectname Programname Linenumber
MG Mud User88f12472016-06-24 23:31:02 +020020
Zesstra715ec202025-07-09 22:18:31 +020021 entry in the resulting array (in verbose mode only).
MG Mud User88f12472016-06-24 23:31:02 +020022
Zesstra715ec202025-07-09 22:18:31 +020023 There is a preconfigured upper limit for the backtrace.
24
25HISTORY
26 Introduced in 3.2.1@34.
27 The absolute stack depth information was added in LDMud 3.2.8.
28
29SEE ALSO
MG Mud User88f12472016-06-24 23:31:02 +020030 debug_message(E)