.


:




:

































 

 

 

 





- , lods, - .
() scans lods, , , , .
, -, 8, 16 32 .
TASM -, :

stos _ (STOre String) - al/ax/eax ;
stosb (STOre String Byte) al ;
stosw (STOre String Word) ax ;
stosd (STOre String Double Word) - eax .

stos

stos _ (STOrage String) - al/ax/eax .

_, .
, ( eax/ax/al) , es:edi/di. edi/di ( df) , .
. , rep, .

5. . .

5. stos ;prg_11_5.asm MASM MODEL small STACK 256 .data ; fnd db 0ah,0dh,' ','$' nochar db 0ah,0dh,' .','$' mes1 db 0ah,0dh,' :','$' string db ' .',0ah,0dh,'$'; mes2 db 0ah,0dh,' , ' db 0ah,0dh,'$' mes3 db 0ah,0dh,' : ','$' .code assume ds:@data,es:@data ds es main:; mov ax,@data; mov ds,ax mov es,ax; es ds mov ah,09h lea dx,mes1 int 21h; mes1 lea dx,string int 21h; string mov al,''; -``() cld; df lea di,string; di string mov cx,29; repne ; string , ; al ; : - cycl: repne scas string je found; found failed:;, , nochar mov ah,09h lea dx,nochar int 21h jmp exit; found: mov ah,09h lea dx,fnd int 21h; ; di ; ; al dec di new_char:; mov ah,09h lea dx,mes2 int 21h; mes2 ; mov ah,01h int 21h; al stos string; ;( al) string mov ah,09h lea dx,mes3 int 21h; mes3 lea dx,string int 21h; string ; inc di; string , ; , jmp cycl; string exit:; mov ax,4c00h int 21h end main;

i386. - . , , DMA (Direct Memory Access ). DMA , , - () .





:


: 2016-12-31; !; : 271 |


:

:

,
==> ...

1746 - | 1680 -


© 2015-2024 lektsii.org - -

: 0.012 .