CHAPTER 1 INTRODUCTION AND LEGAL TERMS Introduction D86 is a screen-oriented assembly language debugger for the IBM-PC, compatibles, and most not-so-compatibles (Wang-PC, TI-PC, Tandy 2000, Sanyo 55x, Zenith Z-100, and DEC Rainbow). D86 is the finest debugger available, at any price under any conditions, for the following: 1. Learning 8086 assembly language. 2. Exploring the machine state of your computer (memory structure, registers, etc.) 3. Doing assembly language program development using my A86 assembler. 4. Doing any kind of debugging involving the floating point (8087 or 287) coprocessor. In contrast to software firms who attempt to restrict the distribution of their software through protection schemes, I encourage free distribution, and trust that those who use my products will pay for them. Please keep in mind the fundamental good spirit of free-distribution software as you endure the following barrage of legalities. Then evaluate the outstanding value that the D86 package offers you. I assure you that you will not be disappointed. Legal Terms and Conditions This package is provided to you under the following conditions: 1. You may copy this entire package, and give it to anyone who accepts these terms. The copies you distribute must be complete and unmodified. You do not have to be registered to distribute this package. 2. Even if you have not yet obtained full execution rights, you may execute the programs in this package, in order to evaluate them. If you decide that D86 is of use to you, you must become a registered user by sending $50 US ($52 overseas) to: Eric Isaacson 416 E. University Ave. Bloomington, IN 47401-4739 For your convenience, I now accept Visa, MasterCard and American Express, by telephone or mail. My number is (812)339-1811. 1-2 For the convenience of users in Great Britain, I have authorized the firm Shareware Marketing to collect registrations for me. We'll try to keep the prices about the same whether you register through me or through them; it's your choice. Their address is 3a Queen St., Seaton, England EX12 2NY; telephone 0297 24088. They'll send me a list of registered users at the end of every month, and I'll send an acknowledgement to each user when I get the list. So if you haven't heard from me by the end of the month following your registration with them, please let me know. Your registration includes the latest diskette (3.5 or 5.25 inch, double density), that also includes the INSTALLD and MAPD86 tools available to registered users only. You may order further updates for $10 US, or $12 US if you are overseas. Once you register for this package, you are registered for all future versions -- you have permanent rights to execute D86 on one computer. As long as I'm in business, you can get the latest version for just the update fee. To use D86, you must have the associated assembler, A86. A copy of A86 (without all of its documentation) is included in the D86 package. If you are using D86 to debug only programs written in languages other than A86, then you do not need to register for A86. If you are programming in A86, then you must register for A86. There is a discount for combined registration of A86 and D86. Instead of $50+$50 = $100, the charge for both packages is $80 ($82 overseas), without the printed manual. I also offer a printed version of this manual, covering both A86 and D86. The manual is printed on sheets 8.5 inches high and 7 inches wide, with a plastic ring-style binding so the book can lay flat. If you order with your registration the manual is an extra $10 to North America, $15 overseas. If you've already registered and now want the manual, add $10 ($12 overseas) for the update disk that the manual is bundled with. There is a limit of one manual per computer registered (except you may reorder when there is a substantial revision to the manual). Indiana residents need to add sales tax. At the current rate of 5%, the prices for Indiana residents are $52.50 for one product, $63 one product with manual, $84 both products, $94.50 both products with manual, $21 manual if already registered. Educational institutions and training facilities MUST be registered in order to use D86 in courses. Contact me for special terms. Companies and government agencies MUST be registered in order to use D86 for their work. Again, contact me for special terms. 1-3 3. You may not sell this package to anyone. If you distribute this package on a diskette, any fees you collect must be specified as materials/handling, and may not exceed $10 for the diskette. 4. You are completely responsible for determining the fitness or usability of this package. I will not be liable for any damages, of any kind, arising from any failure of any programs in this package to perform as expected. Registration Benefits Thank you for enduring the legalities. They are there to protect me, and also to convince you that this is my business, from which I expect to make a living. I'll now return to a softer sell, to try to make you want to register for my products. There is a certain amount of ambiguity about when you're still evaluating D86, and when you're really using D86 and should register for it. Some cases are clear (e.g., you're a school using D86 to teach a course); but many are not. In practical reality, it up to you to decide: you are "on your honor". Also in practical reality, most users who ought to register haven't, yet. For most, it's not dishonesty but merely procrastination. So I have provided some incentives, to prod you into registering. One incentive is the printed manual, which only registered users can purchase. I haven't left anything out of the disk version of the manual, but the printed version is formatted and bound much more nicely than if you print it yourself. Another incentive, included if you register both A86 and D86, is a preliminary test version of A386 and D386. At this writing, all instructions though the Pentium are implemented, except 32-bit indexing (e.g. [EAX]) and assembly to a 32-bit protected-mode segment (in which you need override bytes for 16-bit operands instead of 32-bit operands). Another incentive is a file REG_ONLY.ZIP containing extra tools that enhance D86's usefulness. If you program in languages other than A86, and produce the program with a linker, you can use the tool MAPD86 to convert a link MAP listing into a SYM file readable by D86, so you can do symbolic debugging. If you have a 386-based machine, you can add the D command to D86, allowing you to set memory breakpoints. Finally, there are the intangible incentives. You know you've done the right thing. You're letting me know that you appreciate what I've done. You're letting the world know that quality software can succeed when distributed as shareware. 1-4 Overview of D86 D86 is a screen-oriented program that allows you to troubleshoot faulty computer programs written for the IBM-PC and all compatibles, Wang-PC, TI-PC, Tandy 2000, DEC Rainbow, and Sanyo computer. It "freezes" the state of your program, and allows you to investigate the values of registers, flags, and memory. You can monitor your program's execution by stepping it one instruction or procedure at a time; or you can start your program running, telling D86 to stop it when it reaches certain locations. D86 recognizes the symbol-table output of the A86 assembler, creating a symbolic disassembly of your A86 program, and allowing you to refer to locations and variables by name. The primary design criterion for D86 is ease of use. This is reflected in the most notable features of D86: * You don't need to ask D86 what the values of registers and flags are. They are there, automatically, at a fixed location on the screen. * You don't need to ask D86 where in your program you are stopped. A disassembly is always generated, at another fixed location on the screen. The disassembly gives a hefty chunk of your program, not just the single instruction you are at. A cursor next to the disassembly marks the current location. The disassembly chunk remains fixed as you step though it, allowing you to follow the flow of the program much more easily. If you wrote the program using A86, the disassembly is symbolic, giving instruction operands by name, and labelling disassembly locations when possible. * You don't need to ask D86 what is on the machine stack. A display of the top elements of the stack is always generated, at yet another fixed location on the screen. * You can set up windows into memory, displaying memory contents in a variety of types. The types can even be mixed, to display complicated structures. The windows will stay at the same location until you turn them off, allowing you to watch what your program is doing to those memory locations. * If you have an 8087 or 287 floating-point chip, D86 will generate complete window of the 87 state. The values of the stack elements are in a readable decimal format, with suppression of unneccessary zeroes, and scientific notation only if necessary. * You can, at any time, enable a help-window, to guide you through debugger commands. You will be astounded by the sophistication of this help-facility, especially since other debuggers offer no on-line help whatsoever. * All of the above-mentioned windows, except for the last two, exist on the screen at the same time. You don't have to switch between them. 1-5 * You can single-step your program with single keystrokes, rather than sequences of arcane commands. There are several flavors of single-step keys, clustered together on the function-keypad. This, combined with the automatic nature of the display, allows you to single-step very quickly. You feel like you are actually watching your program run. * Much of D86's command language is simply the A86 assembly language itself. You can type in any A86 instruction, to be executed immediately. You use this to set registers and variables, perform arithmetic, jump to another location, etc. The immediate-execution feature makes D86 the most effective tool available for teaching 86 architecture: the student can watch the effects of instructions on registers, flags, and memory. * You can patch programs in memory, using the full power of the A86 assembly language. How to Contact Me I have no plans to move from my present location at least through the millennium. So you can write to: Eric Isaacson Software 416 East University Ave. Bloomington, IN 47401-4739 or call (812)339-1811. Sorry, I can't guarantee to return everybody's long distance calls. If you'd like to be SURE I'll get back to you, please invite me to call you back collect, or tell me to charge the cost of the call to your credit card. I also have a section on Compuserve: just type GO ZIPKEY to any ! prompt. (ZIPKEY is the name of my other product line, a pop-up zipcode directory.) My Internet address is 71333.3154@compuserve.com. PLEASE contact me if you find bugs in my programs; I'll fix them! I accept bug reports from anyone, registered or non-registered, no questions asked. It's very frustrating to hear about people telling each other about bugs, and not telling me. I still await Greg Wettstein's bug list.