Com 212 intro to system programming book Theory


Op-code In computer technology, an op-code



Download 0.65 Mb.
View original pdf
Page16/72
Date13.05.2021
Size0.65 Mb.
#56617
1   ...   12   13   14   15   16   17   18   19   ...   72
com-212-introduction-to-system-programming-theory
9833 SS1 FISHERY LESSON NOTE
Op-code
In computer technology, an op-code (operation code) is the portion of a machine language instruction that specifies the operation to be performed. Their specification and format are laid out in the instruction set architecture of the processor in question (which maybe a general CPU or a more specialized processing unit. Apart from the opcode itself, an instruction normally also has one or more specifiers for operands (i.e. data) on which the operation should act, although some operations may have implicit operands, or none at all. There are instruction sets with nearly uniform fields for opcode and operand specifiers, as well as others (the x architecture for instance) with a more complicated, varied length structure. Depending on architecture, the operands maybe register values, values in the stack, other memory values, IO ports, etc, specified and accessed using more or less complex addressing modes. The types of operations include arithmetic, data copying, logical operations, and program control, as well as special instructions (such as CPUID and others. Assembly language commands have the following syntax a digit opcode followed by a digit memory address or operand. Each command is stored in a separate memory block. For example
20 0 68 means that in memory block 20, we have a command with the opcode which executes on memory block 68. Finally, the program counter keeps track of the memory block that contains the next command to be executed. By default the program counter is incremented by 1 after each command execution because we typically store commands in consecutive memory blocks. However, the program counter can jump to any memory block depending on the program’s sequence of execution.

Page | 24


Download 0.65 Mb.

Share with your friends:
1   ...   12   13   14   15   16   17   18   19   ...   72




The database is protected by copyright ©ininet.org 2024
send message

    Main page