![]() CATEGORIES: BiologyChemistryConstructionCultureEcologyEconomyElectronicsFinanceGeographyHistoryInformaticsLawMathematicsMechanicsMedicineOtherPedagogyPhilosophyPhysicsPolicyPsychologySociologySportTourism |
Main unprivileged commands. Data transfer.1)mov receiver, source - a team of data transfer. Copies the contents of the source to the receiver, the source does not change. For example: mov ax, 1 ax register assigns a value of 1. Team mov ax, word ptr eax - writes the word ax lying at eax. Byte at address eax recorded in the low half of the ax (in al), and the byte at address eax 1 is written in ah.
2)xchg operand1, operand2 - swaps operands. For example, if the al = 45, ah = 37, then after xchg al, ah is al = 37, ah = 45 3) Addreceiver, source - performs addition of the receiver and the source, the result is stored in the receiver. The source does not change. But changing flags 4) adc receiver, source - receiver performs addition, the source and the flag CF. This command is used to add numbers increased accuracy. Suppose, for example, we have two 64-bit numbers, the first in edx: eax (low-order double word in eax, DWORD senior in edx), the second - in ebx: ecx. Then after executing commands: add eax, ecx; adc edx, ebx; paired registers edx: eax will be the sum of these 64-bit numbers. 5)sub receiver, source - subtracts the source from the receiver, the result puts the receiver 6) sbb receiver, source - subtracts the value of the source of the receiver, and then subtracts the value of CF. It can be used to subtract the 64-bit words 7) increceiver - the same as the add receiver 1 8) dec receiver - the same as the sub receiver 1 9) cmp operand1, operand2 - essentially the subtraction of operanda2 operanda1, only the operands does not change (command only changes the flags). This command is usually executed conditional branches (the most obvious way) 10) and | or receiver, source - performs a logical bitwise AND | OR of the receiver and the source, and places the result into the receiver. Often used to selectively reset | obedinichivaniya individual bits. For example, the command and al, 00001111b will clear upper 4 bits of the register al, and the younger ones will not change 11) xor receiver, source - logical. Performs beaten logical exclusive OR of the receiver and the source, the result is stored in the receiver. Often used to clear the registers. For example, xor ax, ax clears the register ax, and makes it faster than mov ax, 0. 12)testoperand1, operand2 - essentially executes the command and operands, but the operands does not change, but only changes the flags and similar 13) notreceiver - the receiver each bit equal to zero is set to 1, and each bit is equal to 1 is set to 0. The flags are not changed
Command:OUT receiver, source Purpose:Write down data to the port
Date: 2015-01-29; view: 1527
|