Free Essay

Information on 8086

In:

Submitted By nitishnijhawan
Words 6814
Pages 28
INFORMATION OF 8086 WORKING WITH MS-DOS AND BIOS....

The Processing Environment
The processing environment for MASM includes the processor on which your programs run, the operating system your programs use, and the aspects of the segmented architecture that influence the choice of programming models.

8086-Based Processors
The 8086 “family” of processors uses segments to control data and code. The later 8086-based processors have larger instruction sets and more memory capacity, but they still support the same segmented architecture. Knowing the differences between the various 8086-based processors can help you select the appropriate target processor for your programs.
The instruction set of the 8086 processor is upwardly compatible with its successors. To write code that runs on the widest number of machines, select the 8086 instruction set. By using the instruction set of a more advanced processor, you increase the capabilities and efficiency of your program, but you also reduce the number of systems on which the program can run.

Processor Modes

Real mode allows only one process to run at a time. The mode gets its name from the fact that addresses in real mode always correspond to real locations in memory. The MS-DOS operating system runs in real mode.
Windows 3.1 operates only in protected mode, but runs MS-DOS programs in real mode or in a simulation of real mode called virtual-86 mode. In protected mode, more than one process can be active at any one time. The operating system protects memory belonging to one process from access by another process; hence the name protected mode.
Protected-mode addresses do not correspond directly to physical memory. Under protected-mode operating systems, the processor allocates and manages memory dynamically. Additional privileged instructions initialize protected mode and control multiple processes.

8086 and 8088
The 8086 is faster than the 8088 because of its 16-bit data bus; the 8088 has only an 8-bit data bus. The 16-bit data bus allows you to use EVEN and ALIGN on an 8086 processor to word-align data and thus improve data-handling efficiency. Memory addresses on the 8086 and 8088 refer to actual physical addresses.

80186 and 80188
These two processors are identical to the 8086 and 8088 except that new instructions have been added and several old instructions have been optimized. These processors run significantly faster than the 8086.

80286
The 80286 processor adds some instructions to control protected mode, and it runs faster. It also provides protected mode services, allowing the operating system to run multiple processes at the same time. The 80286 is the minimum for running Windows 3.1 and 16-bit versions of OS/2®.

80386
Unlike its predecessors, the 80386 processor can handle both 16-bit and 32-bit data. It supports the entire instruction set of the 80286, and adds several new instructions as well. Software written for the 80286 runs unchanged on the 80386, but is faster because the chip operates at higher speeds.
The 80386 implements many new hardware-level features, including paged memory, multiple virtual 8086 processes, addressing of up to 4 gigabytes of memory, and specialized debugging registers. Thirty-two–bit operating systems such as Windows NT and OS/2 2.0 can run only on an 80386 or higher processor.

80486
The 80486 processor is an enhanced version of the 80386, with instruction “pipelining” that executes many instructions two to three times faster. The chip incorporates both a math coprocessor and an 8K (kilobyte) memory cache. (The math coprocessor is disabled on a variation of the chip called the 80486SX.) The 80486 includes new instructions and is fully compatible with 80386 software.

8087, 80287, and 80387
These math coprocessors work concurrently with the 8086 family of processors. Performing floating-point calculations with math coprocessors is up to 100 times faster than emulating the calculations with integer instructions. Although there are technical and performance differences among the three coprocessors, the main difference to the applications programmer is that the 80287 and 80387 can operate in protected mode. The 80387 also has several new instructions. The 80486 does not use any of these coprocessors; its floating-point processor is built in and is functionally equivalent to the 80387.

Operating Systems
With MASM, you can create programs that run under MS-DOS, Windows, or Windows NT — or all three, in some cases.

MS-DOS

In real-mode programming, you can access system functions by calling MS-DOS, calling the basic input/output system (BIOS), or directly addressing hardware. Access is through MS-DOS Interrupt 21h.

Windows protected mode allows for much larger data structures than real mode, since addressable memory extends to 16 megabytes. In protected mode, segment registers contain selector values rather than actual segment addresses. These selectors cannot be calculated by the program; they must be obtained by calling the operating system. Programs that attempt to calculate segment values or to address memory directly do not work in protected mode.
Protected mode uses privilege levels to maintain system integrity and security. Programs cannot access data or code that is in a higher privilege level. Some instructions that directly access ports or affect interrupts (such as CLI, STI, IN, and OUT) are available at privilege levels normally used only by systems programmers.
Windows protected mode provides each application with up to 16 megabytes of “virtual memory,” even on computers that have less physical memory. The term virtual memory refers to the operating system’s ability to use a swap area on the hard disk as an extension of real memory. When a Windows application requires more memory than is available, Windows writes sections of occupied memory to the swap area, thus freeing those sections for other use. It then provides the memory to the application that made the memory request. When the owner of the swapped data regains control, Windows restores the data from disk to memory, swapping out other memory if required.

Segmented Architecture
The 8086 family of processors employs a segmented architecture — that is, each address is represented as a segment and an offset. Segmented addresses affect many aspects of assembly-language programming, especially addresses and pointers.
Segmented architecture was originally designed to enable a 16-bit processor to access an address space larger than 64K. (The section “Segmented Addressing,” later in this chapter, explains how the processor uses both the segment and offset to create addresses larger than 64K.) MS-DOS is an example of an operating system that uses segmented architecture on a 16-bit processor.
With the advent of protected-mode processors such as the 80286, segmented architecture gained a second purpose. Segments can separate different blocks of code and data to protect them from undesirable interactions. Windows takes advantage of the protection features of the 16-bit segments on the 80286.
Segmented architecture went through another significant change with the release of 32-bit processors, starting with the 80386. These processors are compatible with the older 16-bit processors, but allow flat model 32-bit offset values up to 4 gigabytes. Offset values of this magnitude remove the memory limitations of segmented architecture. The Windows NT operating system uses 32-bit addressing.

Segment Protection

Segmented architecture is an important part of the Windows memory-protection scheme. In a “multitasking” operating system in which numerous programs can run simultaneously, programs cannot access the code and data of another process without permission.
In MS-DOS, the data and code segments are usually allocated adjacent to each other, as shown in Figure 1.1. In Windows, the data and code segments can be anywhere in memory. The programmer knows nothing about, and has no control over, their location. The operating system can even move the segments to a new memory location or to disk while the program is running.

Figure 1.1 Segment Allocation

Segment protection makes software development easier and more reliable in Windows than in MS-DOS, because Windows immediately detects illegal memory accesses. The operating system intercepts illegal memory accesses, terminates the program, and displays a message. This makes it easier for you to track down and fix the bug.
Because it runs in real mode, MS-DOS contains no mechanism for detecting an improper memory access. A program that overwrites data not belonging to it may continue to run and even terminate correctly. The error may not surface until later, when MS-DOS or another program reads the corrupted memory. Segmented Addressing

Segmented addressing refers to the internal mechanism that combines a segment value and an offset value to form a complete memory address. The two parts of an address are represented as segment:offset
The segment portion always consists of a 16-bit value. The offset mode or a 32-bit value in 32-bit mode.
In real mode, the segment value is a physical address that has an arithmetic relationship to the offset value. The segment and offset together create a 20-bit physical address (explained in the next section). Although 20-bit addresses can access up to 1 megabyte of memory, the BIOS and operating system on International Standard Architecture (IBM PC/AT and compatible) computers use part of this memory, leaving the remainder available for programs. Segment Arithmetic
Manipulating segment and offset addresses directly in real-mode programming is called “segment arithmetic.” Programs that perform segment arithmetic are not portable to protected-mode operating systems, in which addresses do not correspond to a known segment and offset.
To perform segment arithmetic successfully, it helps to understand how the processor combines a 16-bit segment and a 16-bit offset to form a 20-bit linear address. In effect, the segment selects a 64K region of memory, and the offset selects the byte within that region. Here’s how it works: 1. The processor shifts the segment address to the left by four binary places, producing a 20-bit address ending in four zeros. This operation has the effect of multiplying the segment address by 16. 2. The processor adds this 20-bit segment address to the 16-bit offset address. The offset address is not shifted. 3. The processor uses the resulting 20-bit address, called the “physical address,” to access an actual location in the 1-megabyte address space. Figure 1.2 illustrates this process. Figure 1.2 Calculating Physical Addresses

A 20-bit physical address may actually be specified by 4,096 equivalent segment:offset addresses. For example, the addresses 0000:F800, 0F00:0800, and 0F80:0000 all refer to the same physical address 0F800.

Language Components of MASM
Programming with MASM requires that you understand the MASM concepts of reserved words, identifiers, predefined symbols, constants, expressions, operators, data types, registers, and statements.

Reserved Words
A reserved word has a special meaning fixed by the language. You can use it only under certain conditions. Reserved words in MASM include:
• Instructions, which correspond to operations the processor can execute.
• Directives, which give commands to the assembler.
• Attributes, which provide a value for a field, such as segment alignment.
• Operators, which are used in expressions.
• Predefined symbols, which return information to your program.
MASM reserved words are not case sensitive except for predefined symbols (see “Predefined Symbols,” later in this chapter).
The assembler generates an error if you use a reserved word as a variable, code label, or other identifier within your source code.

Identifiers

An identifier is a name that you invent and attach to a definition. Identifiers can be symbols representing variables, constants, procedure names, code labels, segment names, and user-defined data types such as structures, unions, records, and types defined with than 247 characters generate an error.

Certain restrictions limit the names you can use for identifiers. Follow these rules to define a name for an identifier:
• The first character of the identifier can be an alphabetic character (A–Z) or any of these four characters: @ _ $ ?
• The other characters in the identifier can be any of the characters listed above or a decimal digit (0–9).
Avoid starting an identifier with the at sign (@), because MASM 6.1 predefines some special symbols

Defining Basic Attributes with .MODEL
The .MODEL directive defines the attributes that affect the entire module: memory model, default calling and naming conventions, operating system, and stack type. This directive enables use of simplified segments and controls the name of the code segment and the default distance for procedures.
You must place .MODEL in your source file before any other simplified segment directive. The syntax is:
.MODEL memorymodel [[, modeloptions ]]
The memorymodel field is required and must appear immediately after the .MODEL directive. The use of modeloptions, which define the other attributes, is optional. The modeloptions must be separated by commas. You can also use equates passed from the ML command line to define the modeloptions.
The following list summarizes the memorymodel field and the modeloptions fields, which specify language and stack distance:

Small, Medium, Compact, Large, and Huge Models
The traditional memory models recognized by many languages are small, medium, compact, large, and huge. Small model supports one data segment and one code segment. All data and code are near by default. Large model supports multiple code and multiple data segments. All data and code are far by default. Medium and compact models are in-between. Medium model supports multiple code and single data segments; compact model supports multiple data segments and a single code segment.
Huge model implies individual data items larger than a single segment, but the implementation of huge data items must be coded by the programmer. Since the assembler provides no direct support for this feature, huge model is essentially the same as large model.

Tiny Model
Tiny-model programs run only under MS-DOS. Tiny model places all data and code in a single segment. Therefore, the total program file size can occupy no more than 64K. The default is near for code and static data items; you cannot override this default. However, you can allocate far data dynamically at run time using MS-DOS memory allocation services.
Tiny model produces MS-DOS .COM files. Specifying argument to the linker. Therefore, the /AT argument is not necessary with /AT does not insert a .MODEL directive. It only verifies that there are no base or pointer fixups, and sends /TINY to the linker.

Creating a Stack

The stack is the section of memory used for pushing or popping registers and storing the return address when a subroutine is called. The stack often holds temporary and local variables.
If your main module is written in a high-level language, that language handles the details of creating a stack. Use the .STACK directive only when you write a main module in assembly language.
The .STACK directive creates a stack segment. By default, the assembler allocates 1K of memory for the stack. This size is sufficient for most small programs.
To create a stack of a size other than the default size, give .STACK a single numeric argument indicating stack size in bytes:
.STACK 2048 ; Use 2K stack

.MODEL ;Sets Memory Model Directive .MODEL name [,language] .MODEL TPASCAL (TASM Only) You use this directive to set the memory model in a program. Memory models set the size limits of the code and data areas for your program. They determine whether the assembler considers data or code references as NEAR or FAR addresses. You must use the .MODEL directive before using the simplified segment directives such as .CODE or .DATA. For the 80386: if you want to use 16-bit segments, use the .386 directive after .MODEL. Otherwise, the assembler defaults to 32-bit segments. The memory model name can be TINY (TASM only), SMALL, MEDIUM, COMPACT, LARGE, or HUGE. Here is a list of memory models and their definitions: Model Means ----- -------------------------------------------------------- TINY Code and Data fit into 64K. The program can be made into a .COM file. This model, also called Small Impure, is available only in Turbo C. SMALL All data fits in one 64K segment, all code fits in one 64K segment. Maximum program size is 128K. MEDIUM All data fits in one 64K segment, but code may be greater than 64K. COMPACT Data may be greater than 64K (but no single array may be), code must be less than 64K. (Turbo: static data must be less than 64K.) LARGE Both data and code may be greater than 64K, but no single array may be. (Turbo: static data must be less than 64K.) HUGE Data, Code, and and data arrays may be greater than 64K. Here is a summary: Model DATA vs. 64K CODE vs. 64K Arrays vs. 64K ----- ------------ ------------ -------------- TINY < < < (TASM only) SMALL < < < MEDIUM < > < COMPACT > < < LARGE > > < HUGE > > > If you want to link your program into a high level language, you should use the same memory model as it does, and specify the name of that language (BASIC, C, PASCAL, or FORTRAN) when you use .MODEL.

HOW TO USE THE DEBUGGER

CONTENTS * Introduction * Pre-Debugger: Syntax Errors * The Debugger * How to Debug * Mechanics of Using TD * Some Pulldown Menus * Breakpoints * CPU Window * Clipboard Facilities * Bottom of page

Introduction
Here is basic information for using a debugger. We will be using the Turbo Debugger. Since this is a fairly complex piece of software, we will help you with some orientation information below. Actually, there are 3 versions of the Turbo Debugger:
TD, TDW and TD32.
(You can find them under the TASM folder.) TD is for 16-bit DOS applications while TDW and TD32 are for 16-bit and 32-bit windows applications. For this course, you only need to use TD. This is what we assume here. But TD only works from a DOS environment. That means that you need to invoke TD from within an MS-DOS PROMPT window (see FAQs for this).
Note that MS-DOS provides an extremely simple debugger called DEBUG. You might find it useful to learn this simple debugger as well (the information on this is in chapter 5 and Appendix E of your text).
Pre-Debugger: Syntax Errors
Before we even approach the debugger, let us address a class of errors for which it is an overkill to use the debugger: that is when you do not even succeed in assembling your program! No object file could be produced. These are basically syntax errors.
The fix here is basically trivial. First note that if you invoke ``tasm hw1'', it will report the line numbers of each instruction that has a syntax error. All you need to do is to address the problems, one offending line at a time! HINT: To ask tasm to print out the actual offending instructions, not just their line numbers, do this instead: :> tasm /z hw1 |
The Debugger
Where does the debugger come in? Well, to debug errors that has to do with the logic of your program. These are sometimes called semantic errors as opposed to the ``syntax errors'' in the previous paragraph. Of course, you can still avoid using a debugger for small programs. When your programs become complex the debugger may be essential.
The first thing to realize is that in order to use the debugger, your assembler and linker needs to store certain additional information needed by the debugger. E.g., if you define the variable Greeting db 'Hello, World!' | then your .obj and .exe files needs to retain the symbolic information telling the debugger that data at offset ABCD0123h (or whatever) is the same as "Greeting". As the human user, you prefer to see the symbolic name "Greeting" rather than "ABCD0123h". To do this, such ``symbolic information'' that are normally discarded by TASM needs to be recorded in the object file it produces. This can be done by calling TASM and TLINK with the options /zi and /v (respectively). Here is a slight revision of the ``First Steps'' instructions used in the TASM notes: :> tasm /zi /z hw1 :> tlink /v hw1 :> td hw1 |
Note that the resulting .obj and .exe files with these options are bigger than they otherwise would be. To see other command options available with tasm or tlink, you can invoke "tasm" or "tlink" without any arguments.
How to Debug
There are 4 basic steps: 1. Discovering the Bug. Is there one? It is not always obvious that you have a bug. (WHY?) 2. Isolating the Bug. Where is it? Locate the part(s) of the code that is causing the bug. 3. Finding the Bug. What exactly is wrong with the buggy code fragment? 4. Fixing the Bug. How should the buggy fragment be rewritten?
The debugger gives you tools to help in all these steps. E.g., you can run the code in a step-by-step fashion or until some breakpoint you set in the code. In between these execution steps, you can examine memory and CPU state (variables, registers, flags and stack).
Mechanics of Using TD
NOTE: It is best to print a copy of this and read it while seated in front of the Turbo Debugger (say, with your hw1 program loaded, using the method suggested above).
Overview The Main TD window shows a standard (pull-down) menu bar at the top. The menu bar lists the following menus: File, Edit, View, Run, Breakpoints, Data, Options, Windows, Help. The status bar at the bottom of the TD window contains helpful information about the current context. For instance, you often see a list of all the functions associated with the function keys F1 to F10. For instance, F9 is the ``Run'' command. That means these functions are available in the current context.
TD Windows Within the Main TD window we can have a variety of (sub)windows. At any moment, several of these windows may be active. Each active windows is numbered (1,2,3, etc.) and this number is displayed on the upper right hand corner of window. Below, we will go into some of these windows and discuss how to manage them. Among the active windows, one of them is the current top window. The top window has a little green rectangle at its upper left corner. You can close this window by clicking on this little green rectangle.
Exercise 1 The function key F6 (called ``Next'') steps through your active windows, allowing each of them to be ``top window'' in turn. Try stepping through your windows: how many windows do you have at this point? What is the current number of active windows? How is the ``top window'' indicated?
Online Help We already mentioned the Help (pulldown) menu. But there are more ``immediate'' or context-sensitive help available: 1. Status Bar We noted that status bar usually shows the list of functions associated with the 10 function keys. But if you hold down the ALT key, the status bar will show the functions associated with ALT+Function Keys.
[E.g., ALT+F5 is the ``User'' Function. Try this! This just gets you back to the MS-DOS Prompt Window. This is useful if you need to see any output from your executed code. To get back from the MS-DOS Prompt, type any key. ]
If you hold down the CTRL key, you will see the CTRL+key functions.
[E.g., CTRL+I allows you to inspect the variable that the cursor is currently pointed at.] 2. Function F1 This key opens a help window containing information about the current top window, with further subtopics to choose from. 3. SpeedMenu This can be invoked with the right mouse click at any time. In most windows, you will get a list of options suitable for that window.
Some Pulldown Menus
Let us go over some of the pulldown menus:
VIEW pulldown menu
The types of windows available are listed under the VIEW menu. We describe three of them here: 1. Module Window This is usually the first window you see, and is number 1. It shows your source code, and so may appear the most familiar to you (after all, you wrote that code!). 2. Watch Window This is usually the second window you see, and thus is number 2. You can set up variables and expressions in this window to ``watch'' (their values change as your program is executed). In fact, exercise 1, you probably saw the Module and Watch Windows (the watch window is quite narrow, and you may miss it). 3. CPU Window This window is most useful for assembly language programming (i.e., for this course!) as it shows the state of your CPU. At the top bar of this window, it will tell you the CPU class (486, Pentium, etc) of the current machine. This window is partitioned into 5 smaller display regions called panes: * Code pane: this pane on the top left is the largest, showing the machine code and disassembled assembly instructions of your executable program. (Source code lines can also be displayed.) * Registers pane: this pane is to the right of the code pane. * Flags pane: this pane is to the right of the registers pane, showing the 8 CPU flag bits. * Dump pane: This is directly below the code pane, showing the hex dump of any memory area accessible by your program. * Stack pane: this is on the bottom right, showing the contents of the program stack (in hex)
For more details, see CPU Window below.
Exercise 2 Write a simple program with these instructions (in addition to the usual stuff): mov ax,0ffffh mov bx,8000h neg bx add ax,bx |
Now load the program into TD, and call up the CPU Window (in addition to the default Module and Watches Windows). Now step through the execution of the program using F7. After each step, describe the contents of ax and bx, and the status flag variables.
WINDOW pulldown menu
This menu helps you manage the various windows. This menu is divided into two halves (separated by a horizontal line): the top half contains commands such as Zoom (=F5), Next (=F6), Next pane (=tab), etc. The bottom half is a list of the currently active windows.
RUN pulldown menu
Windows are for watching. But for action, you need to execute your code. For this, the RUN menu provides several modes of execution: 1. Run (=F9), i.e., until program terminates (or until the next breakpoint). This is the simplest mode. 2. Trace into (=F7 or ALT+F7), i.e., single stepping, instruction by instruction. What constitutes a single step depends on which the current ``top window''. If the top window is the Module window or if you use F7, then a single line of source code is executed. If the top window is the CPU window or if you use ALT+F7, then a single machine instruction is executed. If the current source line contains a function call, TD traces into the function (assuming it was compiled with debug information). Some machine instructions, however, cause multiple instructions to be executed include: CALL, INT, LOOP, etc. 3. Step over (=F8) This is like ``Trace into'' except that when the instruction pointer is at a function call, then the entire function is executed and you are next placed at the statement following the function call. 4. Animate (similar to run until terminate, except it pauses between machine instructions to allow you to catch what is happening) 5. Restart (move the instruction pointer back to the first instruction)
Exercise 3 List the functions available as a CTRL+key functions. List the functions in the SpeedMenu under the Code Pane of the CPU window.
For each of these functions, briefly describe what they do (you can either experiment and/or read up the online help), and describe a debugging situation in which you might find them useful.
Breakpoints
Breakpoints are a device to cause the computer to take specific actions at specific points in its execution. The user can define a breakpoint by specifying three pieces of information. 1. The location where the breakpoint is set. 2. The condition which allows the breakpoint to activate. 3. The action that takes place when the breakpoint is activated.
The simplest kind of breakpoint is one that (a) is associated with a specific instruction in the program, which (b) is always activated (condition is ``always true'') and (c) pauses the program execution (action is ``break''). These are called simple breakpoints. It is the default assumed by TD, and it should suffice for our purposes. Using this, you run the program at full speed until specific instructions, at which points you can examine the state of the memory and CPU.
As an example of more complex breakpoints, you could have a global breakpoint which (a)' is evaluated after each line of source code, which (b)' is activated when a particular variable is modified and (c)' logs the value of an expression.
How do you set simple breakpoints? Well, you only need to specify an instruction in the program. The simplest is to do this from within the Module Window, or from the Code Pane in the CPU Window: * First place the cursor at an executable line of code where a breakpoint is desired. (How do you tell if a line is executable?) You then left-click the 2 leftmost columns of line. Instead of left-click, you can also use function F2 (see the status line). NOTE: if the line already has a breakpoint, then this action removes that breakpoint. Hence this is also called the toggle action. * If you use the Breakpoint->At menu option, you can also place a simple breakpoint at the current cursor position. However, since this has a pop-up Breakpoint option dialog box, you could also specify more complex types of breakpoint.
Breakpoint addresses must be entered when you use the keyboard to enter breakpoints. (You can see this in the Breakpoint option dialog box above.) Here are the kinds of addresses you can specify: * #<number> -- for instance, #68 specifies a breakpoint in line 68 of your source code.
NOTE: If you have several program modules, you need to preface the line number with the module name. E.g. #hw1#68 refers to line 68 in hw1.asm module. * Symbolic names -- for instance, labels can be specified. If you have have a label called ``repeat'', you can use this as an address.
How do you see all the current breakpoints? In the Breakpoints Window, which can be activated using the View->Breakpoints menu option. This window has two panes: the left pane lists all the current breakpoints, the right pane gives details about the breakpoint that is currently highlighted. The SpeedMenu from the left pane has options to add or delete breakpoints, etc.
Exercise 4 Write a simple program using the LOOPE command to read 20 input characters and to store them in a variable called INPUTS. Note that LOOPE is discussed in the exercises of Chapter 6. However, you may break out of the loop early, when a carriage return (CR) is entered. After the last input character, store a '$' character (this is the 21st character if all twenty characters are read, otherwise, the '$' is stored instead of the CR. Use TD to examine the status flags in this loop.
CPU Window
Above we briefly introduced the CPU window. You can activate any pane of the CPU window by left-clicking the pane. The SpeedMenu the activated pane is then available. We now describe two of the panes in more detail.
(1) CODE PANE: There are three display modes in the code pane. In the SpeedMenu for the Code Pane, the command ``Mixed'' accepts three options: ``No'', ``Yes'' and ``Both''. The verbose mode is ``Yes'', and shows for each source code line: * the source code line, * the machine instruction(s), * and the disassembled code in the same line
Note that a source code can generate several machine instructions. For instance, the usual preliminary lines mov ax,@data mov ds,ax | in the procedure main of a program called hw1.asm produces the following information in the code pane: ... #hw1#main: mov ax,@data cs:0000 B8B20A mov ax,0AB2 #hw1#31: mov ds,ax cs:0003 8ED8 mov ds,ax ... |
Note that the first mov instruction produces 3 bytes of machine instructions (B8B20A), the second mov instruction produces only two bytes (8ED8). The offsets of these two instruction in the code segment (cs register) are 0000 and 0003, respectively.
Navigating the code pane. The SpeedMenu in Code Pane has some useful tools for navigating your code: * Origin: positions you at the location of the instruction pointer. * Follow: goes to the destination address of current highlighted instruction. Useful only if the current instruction is a CALL, INT, JMP, JZ, etc. * Previous: restores the code pane to the previous position.
Another useful SpeedMenu command is called Assemble. It allows you to replace the current line of instruction with any other (single) instruction that you specify.
(2) DUMP PANE: This is a hex display of an area in memory. The leftmost path of each line shows the starting address of the line (e.g., ds:0000). In the default display format (byte format), you see 8 bytes per line, and to the right of these 8 bytes are their representation in the IBM extended character set (which is an extension of the ASCII set). You can use the GOTO command in the SpeedMenu to examine variables (e.g., GOTO Input, assuming you have defined the variable "Input"). NOTE: There is also a Dump Window which can be invoked from the View Menu. This gives the same information as the Dump Pane, except that it now can be resized. TRY THIS!
Clipboard Facilities
In debugging, we often have to copy hex addresses or transfer chunks of hex information. Humans tend to make mistakes with such data. TD has extensive copy and paste facilities to and from the Clipboard to help in this process. Hence it is worth your while to learn some tricks for using the Clipboard.
E.g., if a dialog box pops up and asks you for some information (e.g., the address of a breakpoint), it is sometimes possible to paste this information from the clipboard.
The first thing to realize is that information on the clipboard are ``objects'', not just inert data. For instance, if you copy a chunk of the memory to the clipboard, the address of that chunk is remembered. When the contents of these memory locations change, your clipboard contents changes! Hence, each item in the clipboard has an associated type, such as: * address: an address, with no associated data * CPU code: address and byte list of data in memory from the DUMP window * Expression: from the Watches Window * String: a text string
Furthermore, when we paste an item from the clipboard, there are three options: to paste it as a string (if the item is a string), as a location (if item has an address) or as contents (for an address item). Here is how you perform basic clipboard operations: * Copying to Clipboard: position the cursor on the item (or highlight it with the INSERT and arrow keys), then press SHIFT+F3. * Pasting from Clipboard: press SHIFT+F4 (or use the Clip button in some dialog box) to bring up the Clipboard's Pick dialog box. * Viewing the Clipboard contents: choose View->Clipboard menu option.
HOW HOW TO USE TURBO DEBUGGER!!!!Turbo Debugger
Keywords: Assembly language, Turbo Debugger
If you are going to build assembly programs, it might be usefull to actually see that how this works. To achieve this, we are going to use the Turbo Debugger that comes with Borland C compiler. In this tutorial we are going to write a short program using mov instructions. Once we have the .EXE file, we are going to use Turbo Debugger to run this program step by step and see how it works. To make me life easy I wrote a template program, so that I can add the instructions I need to this template. Below, you can see it

IDEAL

MODEL small
STACK 266

;---- Insert INCLUDE "filename" directives here

;---- Insert EQU and = equates here

DATASEG

;---- If an appropriate error occurs and the program should halt, store an appropriate
; error code in exCode and execute a JMP Exit instruction. To do this from a
; submodule, declare the Exit label in an EXTRN directive.

exCode DB 0

;---- Declare other variables with DB, DW, etc, here

speed DB 100 ;one byte variable

;---- Specify an EXTRN variables here

CODESEG

;---- Specify an EXTRN procedure here

Start: mov ax,@data ;initialize DS to address mov ds,ax ;of data segment mov es,ax ; make es=ds

;---- Insert program subroutines calls, etc. here

Exit: mov ah,04Ch ;DOS function: Exit program mov al,[exCode] ;Return the exit code value int 21h ;call DOS. Terminate program

END Start ;End program

Basically, the program loads 10 (Ah), 20 (14h), 30 (1Eh) and 40 (28h) into ax, bx, cx and dx. mov ax,10 mov bx,20 mov cx,30 mov dx,40

Then, the value of speed is loaded into ah and the offest of the "speed" is loaded into si.

mov ah,[speed] ;load the value of speed into ah mov si,offset speed ;load address of speed into al

Save the program as move.asm; assembly and link it program using tasm and tlink. Once you have the .EXE file open a DOS prompt window. Change the directory for C:\Borlandc\Bin. Type then td
The Turbo Debugger application window looks like below

Click on OK. Enlarge the window as much as you can. Using the Open submenu (from File menu) open the move.exe. The program might give you an error message "Program has no symbol table" . Do not worry about that.

Click on OK. Click on the program's window corner and extend it. Now, you can clearly see that there are several "regions". in the biggest region you can see the program. the first one is the program region

In this region you can see the program you wrote. If you pay attention to the above picture you can see move ax,000A, which load in the ax register the value 10 (10 = Ah). The next line will load 20 (14h) in the bx register and so on.

The second region is the register's region.

Here, you can see the each register value. You can see that, for example, the content of ax register is now 0000h.

The third region is the flag's region.

Here, you can see the each flag value.

The fourth region is the flag's region.

Here, you can see some memory locations.

The last region is the stack region.

Here, you can the stack values.

Now, you want to see you program working step by step. To do this, press F8. Once you did that, the prompter goes down one step.

As the first line there is move ax,5108 now, you might see that the content of ax become 5108. In the secod line you move the content of ax into ds. So after executing this line, the content of ds will be 5108 as well.

After executing the third line, the content of es will also become 5108. Press once again F8.

Now, if you press f8 again, you have to see that the content of ax will become 10 (Ah). Before pressing F8 look on the content of ax (which is now 5108).

Now, you will see the value of bx register changing. Now, it is 0000h and it suppose to become 14h (which corresponds to 20).

Now, you will see the value of cx register changing. Now, it is 0000h and it suppose to become 1Eh (which corresponds to 30).

Now, you will see the value of dx register changing. Now, it is 0000h and it suppose to become 28h (which corresponds to 40).

The next register content that will change is ah (the high level byte of it). This will became 64h (corresponding to 99 which is the value of the "speed"). As 99 is lower then 255, this value can be represented using 8 bits. After this step tha value of ax will be 640Ah (al remains unchanged).

The next register content that will change is si. This register will become 0001.

The next step will load 4Ch into the register ah. The content of ax will then became 4C0Ah.

The nest step will make the content of al 0000h. The content of ax will became 4C00h.

And, finally, the last step where the program will call int21 and return to DOS.

The program will let you konw the exit code (if you take a look on the program listing) you defined exCode DB 0. This is the exit code you see now.

You can download the move program from here

Similar Documents

Premium Essay

Data Communication and Networking

...SEMESTER III |SL. |COURSE CODE |COURSE TITLE |L |T |P |C | |NO | | | | | | | |THEORY | |1 |MC9231 |Computer Networks |3 |0 |0 |3 | |2 |MC9232 |Microprocessors and its |3 |0 |0 |3 | | | |Applications | | | | | |3 |MC9233 |Software Engineering |3 |0 |0 |3 | |4 |MC9234 |Computer Graphics |3 |0 |0 |3 | |5 |MC9235 |Web Programming |3 |0 |0 |3 | |PRACTICAL | |6 |MC9237 |Graphics Lab |0 |0 |3 |2 | |7 |MC9238 |Microprocessor Lab |0 |0 |3 ...

Words: 1592 - Pages: 7

Free Essay

Hardware

...These interview questions test the knowledge of x86 Intel architecture and 8086 microprocessor specifically. 1. What is a Microprocessor? - Microprocessor is a program-controlled device, which fetches the instructions from memory, decodes and executes the instructions. Most Micro Processor are single- chip devices. 2. Give examples for 8 / 16 / 32 bit Microprocessor? - 8-bit Processor - 8085 / Z80 / 6800; 16-bit Processor - 8086 / 68000 / Z8000; 32-bit Processor - 80386 / 80486. 3. Why 8085 processor is called an 8 bit processor? - Because 8085 processor has 8 bit ALU (Arithmetic Logic Review). Similarly 8086 processor has 16 bit ALU. 4. What is 1st / 2nd / 3rd / 4th generation processor? - The processor made of PMOS / NMOS / HMOS / HCMOS technology is called 1st / 2nd / 3rd / 4th generation processor, and it is made up of 4 / 8 / 16 / 32 bits. 5. Define HCMOS? - High-density n- type Complimentary Metal Oxide Silicon field effect transistor. 6. What does microprocessor speed depend on? - The processing speed depends on DATA BUS WIDTH. 7. Is the address bus unidirectional? - The address bus is unidirectional because the address information is always given by the Micro Processor to address a memory location of an input / output devices. 8. Is the data bus is Bi-directional? - The data bus is Bi-directional because the same bus is used for transfer of data between Micro Processor and memory or input / output devices in both the direction. 9. What...

Words: 926 - Pages: 4

Free Essay

80386 Microprocessor

...80386 MICROPROCESSOR It is a 32-bit microprocessor. It has 32 bit data bus and 32 bit address bus, so it can address up to 232 = 4GB of RAM. Features -Multitasking -Memory management -Software protection -Segmentation and paging -Large memory system(64Tbytes in virtual mode) Operating modes -Real mode -Protected mode -Virtual mode Internal architecture: There are 6 parallel functional units: -The bus unit: The bus interface unit provides a 32-bit data bus, a 32-bit address bus and control signals. 8-bit (byte), 16-bit (word) and 32-bit (double word) data transfers are supported. It has separate pins for its address and data bus lines. This processing unit contains the latches and drivers for the address bus, transceivers for the data bus, and control logic for signaling whether a memory input/output, or interrupt acknowledgement bus cycle is to be performed. -The prefetch unit: The prefetch unit performs a mechanism known as an instruction stream queue. This queue permits a prefetch up to 16 bytes (8 memory words) of instruction code which is used by the instruction decoder. Whenever bytes are loaded into the queue they are automatically shifted up through the FIFO to the empty location near the output. -The decode unit: It reads the machine-code instructions from the output side of the prefetch queue and decodes them into microcode instruction format...

Words: 4779 - Pages: 20

Free Essay

U1 A1 Intergrated Circuit Technology

...Integrated Circuit Technology U1:A1 ITT-Tech Microprocessor Year Transistor Count 4004 1971 2,300 8008 1972 3,500 8080 1974 4,500 8086 1978 29,000 Intel 286 1982 134,000 Intel 386 Processor 1985 275,000 Intel   486 Processor 1989 1,200,000 Intel Pentium Processor 1993 3,100,000 Intel® Pentium® Pro processor 1995 5,500,000 Intel Pentium II Processor 1997 7,500,000 Intel® Celeron® processor 1998 7,500,000 Intel Pentium III Processor 1999 9,500,000 Intel Pentium 4 Processor 2000 42,000,000 Intel® Xeon® processor 2001 42,000,000 Intel® Pentium® M processor 2003 55,000,000 Intel® Core™2 Duo processor 2006 ...

Words: 455 - Pages: 2

Free Essay

Integrated Circuit Technology

...technology allowing a higher number of transistors and a faster speed than was possible before. 1974: The Intel 8080 was the second 8-bit microprocessor designed and manufactured by Intel and was released in April 1974. It was an extended and enhanced variant of the earlier 8008 design, although without binary compatibility. The initial specified clock frequency limit was 2 MHz, and with common instructions having execution times of 4, 5, 7, 10, or 11 cycles this meant that it operated at an effective speed of a few hundred thousand instructions per second. 1978: The 8086 is a 16-bit microprocessor chip designed by Intel between early 1976 and mid-1978, when it was released. The Intel 8088, released in 1979, was a slightly modified chip with an external 8-bit data bus (allowing the use of cheaper and fewer supporting logic chips[note 1]), and is notable as the processor used in the original IBM PC. The 8086 gave rise to the x86 architecture which eventually turned out as Intel's most successful line of processors. 1993: Pentium microprocessor was introduced on March 22, 1993. Its microarchitecture, dubbed P5, was Intel's fifth-generation and first superscalar x86 microarchitecture. As a direct extension of the 80486 architecture, it included dual integer pipelines, a faster floating-point unit, wider data bus, separate code and data caches and features for further reduced address calculation latency. In 1996, the Pentium with MMX Technology (often simply referred to as Pentium...

Words: 469 - Pages: 2

Premium Essay

History and Transistor Count

...1. Search the Internet using keywords such as “Intel Processor Transistor Count.” 2. Create a table that presents the processor model, year and transistor count for Intel processors from 1971 to the present. 1982 Intel 286 Processor 134K Transistors 1982 Intel 286 Processor 134K Transistors 1978 Intel 8086 Processor 29K Transistors 1978 Intel 8086 Processor 29K Transistors 1974 Intel 8080 Processor 4500 Transistors 1974 Intel 8080 Processor 4500 Transistors 1972 Intel 8008 Processor 3500 Transistors 1972 Intel 8008 Processor 3500 Transistors 1971 Intel 4004 Processor 2300 Transistors 1971 Intel 4004 Processor 2300 Transistors 2003 Intel Pentium M Processor 55 Million Transistors 2003 Intel Pentium M Processor 55 Million Transistors 2001 Intel Xeon Processor 42 Million Transistors 2001 Intel Xeon Processor 42 Million Transistors 2000 Intel Pentium 4 Processor 42 Million Transistors 2000 Intel Pentium 4 Processor 42 Million Transistors 1999 Intel Pentium III Processor 9.5 Million Transistors 1999 Intel Pentium III Processor 9.5 Million Transistors 1998 Intel Celeron Processor 7.5 Million Transistors 1998 Intel Celeron Processor 7.5 Million Transistors 1995 Intel Pentium Pro Processor 5.5 Million Transistors 1995 Intel Pentium Pro Processor 5.5 Million Transistors 1997 Intel Pentium II Processor 7.5 Million Transistors 1997 Intel Pentium II Processor 7.5 Million Transistors 1993 Intel Pentium...

Words: 571 - Pages: 3

Free Essay

Unit 1 Assignment 1 - Integrated Circuit Technology

...Model | | Year | | | Transistor Count | | | | 4004 | | 1971 | | | 2,300 | | | | 8086 | | 1978 | | | 29,000 | | | | Intel 486 Processor | | 1989 | | | 1,200,000 | | | | Intel Itanium 2 Processor | | 2004 | | | 592,000,000 | | | | Intel 9300 Tukwila Processor | | 2010 | | | 2,000,000,000 | | | | * The transistor count reached a 2,000,000,000 count in the year of 2010 * The name of this processor was Quad-Core Itanium Tukwila * I believe the growth is reasonable. From the advances we’ve made from the 70’s to now such as the cell phone, laptops, hand held devices. It’s no surprise that it increased so much each year. We are able to grow rapidly, and we are in a generation of technology. It wouldn’t be crazy to think that this was possible from seeing other devices progress as well, even now you can hold a computer in the palm of your hand. * The growth from 1971-2014 is outstanding. The first couple years they were released the processors had very few transistors and didn’t increase that much yearly. However, after 1974 with each year the amount of chips almost doubled itself each year. Afterwards with the years to come, the growth rapidly increased. By the year 2010 the transistor count reached 2 billion with the release of the Quad-Core Itanium Tukwila processor. * With this information it’s hard to predict when it could reach 100 billion transistors on a single chip, however seeing the growth from...

Words: 332 - Pages: 2

Free Essay

Complogic

...Model | Year | Transistor Count | Intel 4004 | 1971 | 2,300 | Intel 8008 | 1972 | 3,500 | Intel 8080 | 1974 | 4,500 | Intel 8085 | 1976 | 6,500 | Intel 8086 | 1978 | 29,000 | Intel 8088 | 1979 | 29,000 | Intel 80186 | 1982 | 55,000 | Intel 80286 | 1982 | 134,000 | Intel 80386 | 1985 | 275,000 | Intel 80486 | 1989 | 1,180,000 | Pentium | 1993 | 3,100,000 | Pentium II | 1997 | 7,500,000 | Pentium III | 1999 | 9,500,000 | Pentium 4 | 2000 | 42,000,000 | Atom | 2008 | 47,000,000 | Itanium 2 | 2003 | 220,000,000 | Core 2 Duo | 2006 | 291,000,000 | Itanium 2 w/ 9MB Cache | 2004 | 592,000,000 | Core i7 Quad | 2008 | 731,000,000 | Six-Core Xeon 7400 | 2008 | 1,900,000,000 | Six-Core Core i7 | 2010 | 1,170,000,000 | Dual-Core Itanium 2 | 2006 | 1,700,000,000 | Quad-Core Itanium Tukwila | 2010 | 2,000,000,000 | 8-Core Xeon Nehalem-E-X | 2010 | 2,300,000,000 | 10-Core Xeon Westmere-E-X | 2011 | 2,600,000,000 | The year that 2 billion transistors were introduced on a single processor chip was 2010. I believe that the growth pattern for Intel is definitely reasonable. It is a fast growth rate and computer technology seems to jump at a high rate every 2 years. I think that by the year 2022 we will have 100 billion transistors on the processor chip. All of the sources for the information on this page can be found at http://en.wikipedia.org/wiki/Transistor_count. Though I don’t always trust Wikipedia, it was the best diagram available for this...

Words: 279 - Pages: 2

Free Essay

Unit3

...Assignment #3 Tajuan Akins Kaplan University Online IT 332 Principles of Information Systems Architecture Professor June 2, 2014 I attest that this is my original work. I have not used unauthorized source of information - including paid sites/services - either modified or unmodified. I attest that the only source of information used in the development of this project has been retrieved from the course textbook and those sources listed within the documentation that is being provided as part of this assignment. I have not given other fellow student(s) access to my code, script, diagram, etc., in any form. Part 1. Project Definition Instruction set architecture (ISA) describes the processor in terms of what the assembly language programmer sees the instructions and registers. All computer programs are translated to machine code for execution by the CPU. Once a program has been loaded into the computer’s memory. The program may then be executed. Many modern processor designs are so called RISC (Reduced Instruction Set Computer) designs which use relatively small instruction sets, in contrast to so called CISC designs such as the VAX and machines based on the Intel 8086 and Motorola 68000 microprocessor families. Operating instructions also include instructions that move data between registers and manipulate stacks. Memory-access instructions are those that transfer data between registers and memory. The CPU carries out the instructions that it finds in the...

Words: 531 - Pages: 3

Free Essay

Computer Model

...KENDRICK BANKS INTEGRATED CIRCUIT TECHNOLOGY YEAR MODELd IN 1971 INTEL 4004 2300 1972 INTEL 8008 3500 1974 INTEL 8080 4500 1976 INTEL 8085 4500 1978 INTEL 8086 2900 1979 INTEL 8088 2900 1982 INTEL 80286 134,000 1985 INTEL 80386 275,000 1988 INTEL i960 250,000 1989 INTEL 80486 1,180,235 1993 PENTIUM 3,100,000 1995 PENTIUM PRO 5,500,000 1997 PENTIUM II KLAMATH 7,500,000 1998 PENTIUM II DESCHUTES 7,500,000 1999 PENTIUM III KATMAI 9,500,000 2000 PENTIUM III COPPERMINE 21,000,000 2001 PENTIUM III TUALATIN 45,000,000 2002 PENTIUM 4 NORTHWOOD 55,000,000 2003 ITSNIUM 2 MSFIDON 6M 410,000,000 2004 PENTIUM 4 PRESCOTT 112,000,000 2005 PENTIUM 4 PRESCOTT-2M 169,000,000 2006 PENTIUM 4 CEDAR MILL 184,000,000 2007 CORE 2 DUO 169,000,000 2008 ATOM 47,000,000 2010 SIX-CORE CORE i7 1,170,000,000 2011 QUAD-CORE+GPU CORE i7 1,160,000,000 2012 8-CORE AMD BULLDOZER 1,200,000,000 2014 15-CORE XEON IVY BRIDGE-EX 4,310,000,000 In 2010 Intel came out with the Quad-Core Itanium Tukila that had 2 billion transistors. I think that over the years will go up a lot. Although it will go up at one point it will drop just a little seams to be every 3 to 4 years http://en.wikipedia.org/wiki/Transistor_count TASK 1: PROCEDURE MEMORY HOLDIN (RAM)-THIS IS THE PRIMARY WORKING MEMORY WICH HOLDS ALL THE PROGRAMS AND DATA THE PROCESSOR IS USING AT A TIME...

Words: 426 - Pages: 2

Free Essay

Unit 1 Assignment 1

...motherboard is the backbone of the personal computer, it transfers information and power to all the other components. The motherboard is the largest board inside of the computer that contains the basic input and output system that allows every component to communicate with one another. Attached to the motherboard is a chip comprised with dozens of pins called the central processing unit. Along with the CPU attached to the motherboard is the dual-inline memory modules a part of the random access memory. RAM is the most common type of memory used another type is ROM, read only memory, which stores data onto metal disc within the device. The operating system manages the hardware resources and provides a place to run programs. The last components of the personal computer are the tower and the human interface devices. The tower holds all the components that make up the computer except for the HID which are located outside of the computers tower. The main purpose of the HID’s are to help us interact with the computer, a few examples are the keyboard, mouse, monitor, video camera and speakers. You put together the Motherboard, CPU, RAM, ROM, OS, Tower, HID’s add a power supply and you have a basic personal computer. PROCESSOR TRANSISTOR YEAR Intel 4004 | 2,300 | 1971 | Intel 8008 | 3,500 | 1972 | Intel 8080 | 4,500 | 1974 | Intel 8085 | 6,500 | 1976 | Intel 8086 | 29,000 | 1978 | Intel 80386 | 275,000 | 1985 | Intel...

Words: 427 - Pages: 2

Free Essay

Nt1110 U1As1 Integrated Circuit Technology

...Integrated Circuit Technology (U1AS1) Processor Model | Transistor Count | Year | Intel 4004 | 2,300 | 1971 | Intel 8008 | 3,500 | 1972 | Intel 8080 | 4,500 | 1974 | Intel 8086 | 29,000 | 1978 | Intel 286 | 134,000 | 1982 | Intel 386 | 275,000 | 1985 | Intel 486 | 1,200,000 | 1989 | Intel Pentium | 3,100,000 | 1993 | Intel Pentium Pro | 5,500,000 | 1995 | Intel Pentium II | 7,500,000 | 1997 | Intel Celeron | 7,500,000 | 1998 | Intel Pentium III | 9,500,000 | 1999 | Intel Pentium 4 | 42,000,000 | 2000 | Intel Xeon | 42,000,000 | 2001 | Intel Pentium M | 55,000,000 | 2003 | Intel Core 2 Duo | 291,000,000 | 2006 | Intel Core i7 (quad) | 731,000,000 | 2008 | Intel Quad-Core Itanium | 2,000,000,000 | 2010 | Intel Six-Core i7/8 | 2,270,000,000 | 2011 | Intel 8-Core Itanium | 3,100,000,000 | 2012 | The processor chip that has two billion transistors placed in it was the Intel Quad-Core Itanium, which was released in 2010. Source: 1. http://www.intel.com/content/dam/www/public/us/en/documents/corporate-information/museum-transistors-to-transformations-brochure.pdf 2. http://www.wagnercg.com/portals/0/funstuff/AHistoryofMicroProcessorTransistorCount.pdf The growth of the transistor is reasonable because computer technology grew and it will keep growing, which Moore’s law proves that the growth...

Words: 283 - Pages: 2

Free Essay

Unit 1 Assignment 1: Integrated Circuit Technology

...Unit 1 Assignment 1: Integrated Circuit Technology Processor Model | Year | Transistor Count | Intel 4004 | 1971 | 2,300 | Intel 8008 | 1972 | 3,500 | Intel 8080 | 1974 | 4,500 | Intel 8085 | 1976 | 6,500 | Intel 8086 | 1978 | 29,000 | Intel 8088 | 1979 | 29,000 | Intel 80186 | 1982 | 55,000 | Intel 80286 | 1982 | 134,000 | Intel 80386 | 1985 | 275,000 | Intel 80486 | 1989 | 1,180,000 | Pentium | 1993 | 3,100,000 | Pentium II | 1997 | 7,500,000 | Pentium III | 1999 | 9,500,000 | Pentium 4 | 2000 | 42,000,000 | Itanium 2 | 2003 | 220,000,000 | Itanium 2 with 9MB cache | 2004 | 592,000,000 | Core 2 Duo | 2006 | 291,000,000 | Dual-Core Itanium 2 | 2006 | 1,700,000,000 | Atom | 2008 | 47,000,000 | Core i7 (Quad) | 2008 | 731,000,000 | Six-Core Xeon 7400 | 2008 | 1,900,000,000 | Six- Core i7 (Gulftown) | 2010 | 1,170,000,000 | 8-Core Xeon Nehalem-EX | 2010 | 2,300,000,000 | Quad-Core Itanium Tukwila | 2010 | 2,000,000,000 | Six- Core Core i7 (Sandy-Bridge-E) | 2011 | 2,270,000,000 | 10-Core Xeon Westmere-EX | 2011 | 2,600,000,000 | 8-Core Itanium Poulson 2012 3,100,000,000 62-Core Xeon Phi 2012 5,000,000,000 Haswell 2013 1,400,000,000 Moore’s Law- Overall processing power will double every two years. Following Moore’s Law we should see a transistor count of over a hundred billion by the year 2022 and a trillion by...

Words: 384 - Pages: 2

Free Essay

Proposal

...8086 assembler tutorial for beginners (part 2) Memory Access to access memory we can use these four registers: BX, SI, DI, BP. combining these registers inside [ ] symbols, we can get different memory locations. these combinations are supported (addressing modes): [BX + SI] [BX + DI] [BP + SI] [BP + DI] | [SI] [DI] d16 (variable offset only) [BX] | [BX + SI + d8] [BX + DI + d8] [BP + SI + d8] [BP + DI + d8] | [SI + d8] [DI + d8] [BP + d8] [BX + d8] | [BX + SI + d16] [BX + DI + d16] [BP + SI + d16] [BP + DI + d16] | [SI + d16] [DI + d16] [BP + d16] [BX + d16] | d8 - stays for 8 bit signed immediate displacement (for example: 22, 55h, -1, etc...) d16 - stays for 16 bit signed immediate displacement (for example: 300, 5517h, -259, etc...). displacement can be a immediate value or offset of a variable, or even both. if there are several values, assembler evaluates all values and calculates a single immediate value.. displacement can be inside or outside of the [ ] symbols, assembler generates the same machine code for both ways. displacement is a signed value, so it can be both positive or negative. generally the compiler takes care about difference between d8 and d16, and generates the required machine code. for example, let's assume that DS = 100, BX = 30, SI = 70. The following addressing mode: [BX + SI] + 25 is calculated by processor to this physical address: 100 * 16 + 30 + 70 + 25 = 1725. by default DS segment register is used for all modes except those...

Words: 2749 - Pages: 11

Free Essay

Nt1110 Unit 1

...Intel 4004 1971 2,300 Intel 8008 1972 3,500 Intel 8080 1974 4,500 Intel 8085 1976 6,500 Intel 8086 1978 29,000 Intel 8088 1979 29,000 Intel 80186 1982 55,000 Intel 80286 1982 134,000 Intel 80386 1985 275,000 Intel 80486 1989 1,180,235 Pentium 1993 3,100,000 Pentium Pro 1995 5,500,000 Pentium II 1997 7,500,000 Pentium 4 2000 42,000,000 Itanium 2 McKinley 2002 220,000,000 Itanium 2 Madison 6M 2003 410,000,000 Atom 2008 47,000,000 Itanium 2 with 9MB cache 2004 592,000,000 Dual-Core Itanium 2 2006 1,170,000,000 Core 2 Duo 2006 291,000,000 Core i7 (Quad) 2008 731,000,000 Six-Core Xeon 7400 2008 1,900,000,000 Quad-Core+GPU Core i7 2011 1,160,000,000 Six-Core Core i7 (Gulftown) 2010 1,170,000,000 Quad-Core Itanium Tukwila 2010 2,000,000,000 8-Core Xeon Nahalem-EX 2010 2,300,000,000 Six-Core Core i7/8-Core Xeon E5 2011 2,270,000,000 10-Core Xeon Westmere-EX 2011 2,600,000,000 Quad-Core+GPU Core i7 2012 1,400,000,000 8-Core Itanium Poulson 2012 3,100,000,000 62-Core Xeon Phi 2012 5,000,000,000 Source: Wikipedia August 29, 2013 A History of Microprocessor Transistor Count. Retrieved from www.wagnercg.com Once the transistor was introduced to the processing unit for computers our interactions with information will never be the same. As you can see from the information above that once the public and businesses saw the potential of what could be accomplished enough was never...

Words: 516 - Pages: 3