.. . . ..
΢»úÔÀíµÚÆßÕ´ð°¸
7.3 ÉèAX=1122,BX=3344H,CX=5566H,SS=095BH,SP=0040H,ÏÂÊö³ÌÐòÖ´ÐÐ
ºóAX£¬BX£¬CX£¬DX 4¸öͨÓüĴæÆ÷ÄÚÈÝÊǶàÉÙ£¿»³ö¶ÑÕ»´æ´¢Æ÷µÄÎïÀíµØÖ·¼°´æ´¢ÄÚÈݺÍSPÖ¸ÏòµÄʾÒâͼ¡£ PUSH AX PUSH BX PUSH CX POP BX POP AX POP DX
²Î¿¼´ð°¸£º(BX)=5566H, (AX)=3344H, (DX)=1122H£¬(CX)=5566H ¶ÑÕ»¶ÎÎïÀíµØÖ·=SS*16(×óÒÆ4λ)+SP 66H 095EBH 55H 44H 095ECH 33H 22H 095FDH 11H 095EEH 095EFH
SP¡ú 095F0H . ѧϰ°ïÊÖ .
.. . . ..
7.4 Éè SP=0040H,Èç¹ûÓýøÕ»Ö¸Áî´æÈë5¸öÊý¾Ý£¬ÔòSP=0036H £¬ÈôÓóöÕ»
Ö¸ÁîÈ¡³öÁ½¸öÊý¾Ý£¬ÔòSP=003AH ¡£
7.5½«±íÖгÌÐò¶Î¸÷Ö¸ÁîÖ´ÐкóAXµÄÖµÓÃÊ®Áù½øÖÆÊýÌîÈë±íÖÐ
²Î¿¼´ð°¸£º ³ÌÐò¶Î MOV AX,0 DEC AX ADD AX,7FFFH ADC AX,1 NEG AX
AX 0 FFFFH 7FFEH 8000H 8000H ³ÌÐò¶Î OR AX,3FDFH AND AX,0EBEDH XCHG AH,AL SAL AX,1 RCL AX,1 AX BFDFH ABCDH CDABH 9B56H 36ADH 7.6 ÓÃÊ®Áù½øÖÆÊýÌîÏÂ±í£¬ÒÑÖªDS=1000H,ES=2000H,SS=0FC0H,ͨÓüĴæÆ÷
µÄֵΪ0¡£
²Î¿¼´ð°¸£ºÂß¼µØÖ·=¶Î»ùÖ·£º¶ÎÄÚÆ«ÒƵØÖ·
BPÒÔSSΪĬÈ϶λùÖ·£¬ÆäÓà¼Ä´æÆ÷ÒÔDSΪĬÈ϶λùÖ· ES£ºÎª¶Îǰ׺£¬ÒÔESΪ¶Î»ùÖ· Ö¸Áî SUB [BP],AL ´æ´¢Æ÷²Ù×÷ÊýÂß¼µØÖ· 0FC0H:0000H . ѧϰ°ïÊÖ .
.. . . ..
MOV [BX],BH MOV [DI],DL MOV ES:[SI],BL ADD 500H[BP],AH SUB [SI-300H],AL MOV 1000H[DI],DL MOV [BX-8],CL MOV ES:1000H[DI],CH MOV [BP+SI],DH MOV [BX+DI],DL
1000H:0000H 1000H:0000H 2000H:0000H 0FC0H:0500H 1000H:FD00H 1000H:1000H 1000H:FFF8H 2000H:1000H 0FC0H:0000H 1000H:0000H 7.7 ÊÔ¸ø³öÖ´ÐÐÍêÏÂÁÐÖ¸ÁîºóOF¡¢SF¡¢ZF¡¢CF4¸ö¿É²âÊÔ±ê־λµÄ״̬£¨ÓÃÊ®
Áù½øÖƸø³öFLAGµÄÖµ£¬ÆäÓà¸÷λΪ0£©
(1)MOV AX,2345H (2) MOV BX,5439H ADD AX,3219H ADD BX,456AH (3)MOV CX,3579H (4) MOV DX,9D82H SUB CX,4EC1H SUB DX,4B5FH OF DF IF Òç³ö ·½Ïò ÖÐ¶Ï TF SF ZF 0 ÏÝÚå ·ûºÅ ΪÁã AF 0 ¸¨½ø PF 0 ÆæÅ¼ CF ½øÎ»
. ѧϰ°ïÊÖ .
.. . . ..
²Î¿¼´ð°¸£º£¨ÕâÀï³ýÁËÉÏÃæ4¸ö±êÖ¾»¹¿¼ÂÇÁËÆæÅ¼±êÖ¾PFºÍ¸¨Öú½øÎ»±êÖ¾AF£© £¨1£©AX=555EH FLAG=0000H 0 0 0 0 OF DF IF 0 0 0 TF SF ZF 0 0 0 0 0 AF 0 0 0 PF 0 0 0 CF 0 £¨2£©BX=99A3H FLAG=0894H 0 0 0 0 OF DF IF 1 0 0 TF SF ZF 0 0 1 0 0 AF 0 1 0 PF 0 1 0 CF 0 £¨3£©CX=E6B8 FLAG=0081H 0 0 0 0 OF DF IF 0 0 0 TF SF ZF 0 0 1 0 0 AF 0 0 0 PF 0 0 0 CF 1 £¨4£©DX=5223 FLAG=0014H 0
0 0 0
OF DF IF 0 0 0 TF SF ZF 0 0 0 0 AF 1 0 PF 0 1 0 CF 0 7.8 AX ÖÐÓÐÒ»¸ºÊý£¬ÓûÇóÆä¾ø¶ÔÖµ£¬Èô¸ÃÊýΪ²¹Â룬ÔòʹÓÃÖ¸Áî NEG
AX £»ÈôΪÔÂëÔòÓÃÖ¸ÁîAND AX£¬7FFFH¡£ ¡£
7.9 ·Ö±ðд³öʵÏÖÈçϹ¦ÄܵijÌÐò¶Î£º
£¨1£©½«AXÖмä8루×ö¸ß8룩£¬BXµÍ4λºÍDX¸ß4루×öµÍ4λ£©Æ´³ÉÒ»¸öÐÂ×Ö¡££¨×¢Ò⣺×óÒÆÓÒÒÆ²Ù×÷£©
AND AX£¬0FF0H MOV CL,04H
. ѧϰ°ïÊÖ .