1. About
This is a clone of the MS-DOS DEBUG command. Some minor things aren't
implemented. OTOH it has many features not available in the original
MS DEBUG. For details see below.
2. Files Overview
The files in this distribution are:
debug.com the executable binary.
debugx.com a DPMI aware version of debug.
debxxvdd.dll a Win32 dll (VDD) loaded if debugx runs in a Windows XP
NTVDM "DOS box". Makes debugx's L and W command work with
sectors on this platform.
debug.asm Assembler source code for DEBUG.
Assemble with Masm or JWasm.
debugtbl.inc include file for debug.asm, generated by mktables.
instr.* data files on the instruction set.
mktables.c C program to compile the internal instruction-set
tables into source file debugtbl.inc. It runs under
Linux or Turbo C (version 2.0, at least).
Open Watcom v1.5 WCC works as well.
readme.txt this file.
debug.txt a DEBUG tutorial originally written by Michael Webster,
extended to describe all additional features of FD DEBUG.
SAMPLES contains samples of 16 and 32-bit DPMI clients in Masm
and Nasm syntax.
3. Missing/Added Features
a. The following are not implemented:
- Loading of .HEX files.
b. This debugger extends the MS-DOS version in the following ways:
- The assembler and disassembler support all publicly documented
instructions for Intel chips through the Pentium Pro (P6), except for
the MMX instructions. The assembler and disassembler inform you if
any instruction is inappropriate for the current processor.
- FPU Opcodes are supported.
- The current processor (for the purposes of assembler and disassembler
warnings, above) can be declared to be something else via the following
commands:
m [x] set current processor.
x=0 current processor is 8088.
x=1..6 current processor is 80x86. 80586 is a Pentium and
80686 is a Pentium Pro.
no argument = print current CPU/FPU types.
mc [2|N] set math coprocessor.
2 = math coprocessor is a 287 (only valid if current
processor is a 386).
N = math coprocessor is absent
no argument = math coprocessor is present
- 'r register [value]' accepts 32-bit register names (for cpu 80386+).
- You can do `r cx 1234' instead of having to put the `1234' on a
separate line.
- 'rn' displays FPU register status (currently for cpu 80386+ only)
Just the raw hex values of the registers are displayed, though.
- 'rx' switches among 8086 and 80386 register display (for cpu 80386+).
- When doing `debug < file', debug will not hang if it reaches an end of
file before encountering a `q' command.
- This debugger saves and restores the program's Control-C and critical
error interrupts, providing for better isolation between the debugger
and the program being debugged.
- 'tm 0|1' sets trace command mode, 0 = process INTs (default),
1 = single-step INTs (the MS-DOS Debug compatible mode).
- 'xr' allows to reallocate an EMS handle and 'xa' allows to allocate
an "empty" EMS handle (with zero pages) - but only if an EMM v4.0
is present.
- Besides 'i' and 'o' exist the variations 'iw', 'id', 'ow' and 'od'
to read/write a WORD or DWORD value from/to a port [DWORD values
require a 80386+ cpu].
- 'h' can handle dword values.
- register names can be used anywhere where a number is expected as
input. That is, things like "u cs:ip" do work.
- 'dm' displays the DOS memory control block (MCB) chain and the
current PSP.
- if DOS has set its InDOS flag, DEBUG will avoid to use int 21h
internally, which allows to single-step through DOS code.
- 'd', 't' and 'u' are automatically repeated if a blank line is
entered.
c. A DPMI aware version of the debugger, DEBUGX, is available, with the
following additional features:
- besides real-mode applications it can debug both 16-bit and 32-bit
DPMI clients.
[To debug DPMI clients a DPMI host has to be installed. Tested with
cwsdpmi, hdpmi, WinXP NTVDM, 32rtm. In DosEmu and Windows 95/98/ME
DOS boxes it is required to single-step through the initial switch
to protected-mode, else DEBUGX will loose control of the debuggee.]
- 'dl': display LDT descriptor(s) (in protected-mode only)
- 'di': display interrupt vector(s)
- 'dx': display extended memory (read via Int 15h, ah=87h). Requires a
80386 cpu. 'dx' is automatically repeated if a blank line is entered.
- 'rn' displays FPU registers in "readable" format.
- when running in a Windows XP DOS bos, DEBUGX will try to load and use
DEBXXVDD.DLL. This DLL will allow DEBUGX to successfully execute its
low-level disk access commands L and W in this OS - if the user has
administrator rights. DEBXXVDD.DLL is public domain, the source can
be downloaded from http://www.japheth.de/Download/debxxvdd.zip. Please
be aware that you can do severe damage to your disk data if you use
those low-level functions without knowing what you are doing.
4. History
0.95e [11 January 2003] Fixed a bug in the assember.
0.95f [10 September 2003] Converted to NASM; fixed some syntax
incompatibilities.
0.98 [27 October 2003] Added EMS commands and copyright conditions.
------- changes below were done by me, japheth
0.99 [27 Septemb 2006]
- bugfix: IF was not displayed correctly.
- FS and GS registers displayed if cpu is 80386+.
- RX displays the standard 32bit registers.
- R register [value] understands the standard 32bit registers.
0.99a [28 Septemb 2006]
- bugfix: JECXZ had wrong prefix (66h, should be 67h).
- A and D understand the 32bit opcodes LOOP(Z|NZ|E|NE)D.
0.99b [29 Septemb 2006]
- L and W now work with FAT32 drives.
0.99c [29 Septemb 2006]
- RX changed. Now it toggles 16/32 bit register dump.
- RN displays floating point register status.
0.99d [02 October 2006]
- bugfix: RN displayed error-pointer registers wrong.
0.99e [12 October 2006]
- XR command added to reallocate EMS handle.
- XA command allows to allocate zero pages on EMS 4.0.
- TM [0|1] added to be able to switch T to the ms-dos debug
compatible behaviour (that is, T jumps into 'INT xx').
0.99f [17 October 2006]
- debug's EMS functions may work even with a "hidden" EMM.
- bugfix: display of mappable pages didn't account for amount of
these pages == 0.
0.99g [25 October 2006]
- bugfix: U was unable to recognise [ESP] related memory operands
(i.e. mov eax,[esp]).
0.99h [07 November 2006]
- bugfix: R trying to display content of effective address has
caused a GPF in v86-mode if this address was FFFFh of FFFDh.
- IW, ID, OW and OD implemented.
0.99i [14 November 2006]
- bugfix: a child PSP was created but not terminated, causing files
not to be closed. It became obvious if stdin and/or stdout were
redirected to files ("C:\>DEBUG >yyy")
0.99j [16 November 2006]
- bugfix: using T if current instruction is an INT xx (and trace
mode == 0) stopped debuggee one instruction *after* the INT (due
to a x86 design weakness).
- bugfix: the 0.99i bugfix had some problems on FreeDOS.
1.00 [25 November 2006]
- bugfix: debuggee's psp was saved after program load only, but
this has to
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
DEBUG117.zip (23个子文件)
README.TXT 14KB
DEBUG.TXT 27KB
DEBUG.COM 22KB
MKTABLES.C 28KB
FPTOSTR.INC 8KB
SAMPLES
DPMICL32.COM 252B
MAKEN.BAT 136B
DPMICL16.COM 225B
DPMICL16.NSM 2KB
MAKEJ.BAT 235B
DPMICL16.ASM 2KB
DPMICL32.ASM 2KB
DPMICL32.EXE 348B
DPMICL32.NSM 2KB
DEBUGX.COM 27KB
INSTR.SET 9KB
DEBUGTBL.INC 36KB
MAKEC.BAT 256B
DEBUG.ASM 208KB
INSTR.KEY 2KB
MAKE.BAT 189B
DEBXXVDD.DLL 3KB
INSTR.ORD 566B
共 23 条
- 1
资源评论
- yasong20152012-04-02没用上,这个算不错吧。我是将word中的脚本调试的那个勾上,就可以在IE上出项脚本调试。。。
ljhhh0123
- 粉丝: 84
- 资源: 73
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功