我已经使用命令创建了我的 asm 代码的列表文件
cd c:\masm32\bin\
ml.exe /c /Fl"c:\path\file.lst" /Sc "c:\path\file.asm"
lst 文件包含三列:第一列是特定行的十六进制地址,第三列是操作码,但我不明白第二列中的值的含义。我认为它被称为“计时”,其值类似于:2
或 10m
甚至 7m,3
。这些数字的含义是什么?它们代表什么?
最佳答案
With the
/Sc
command-line switch, which generates instruction timings, each line has this syntax:offset [[timing]] [[code]]
The
offset
is the offset from the beginning of the current code segment. Thetiming
shows the number of cycles the processor needs to execute the instruction. The value oftiming
reflects the CPU type; for example, specifying the.386
directive produces instruction timings for the 80386 processor. If the statement generates code or data, code shows the numeric value in hexadecimal notation if the value is known at assembly time. If the value is calculated at run time, the assembler indicates what action is necessary to compute the value.When assembling under the default
.8086
directive, timing includes an effective address value if the instruction accesses memory. The 80186/486 processors do not use effective address values. For more information on effective address timing, see the "Processor" section in the Reference book.
( source )
我不确定我对这些计时值的信任程度,除非您实际上要在 80486 或更早的处理器上执行代码。
关于file - MASM 程序集列表文件 - 解释,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29488745/