Scas-string manipulation instruction-microprocessor, Assembly Language

Assignment Help:

SCAS : Scan String Byte or String Word:-

This instruction scans a string of words or byte for an operand word or byte specified in the register AL or  register AX. The string is pointed to by ES: DI register pair. The length of the string is stored in register CX. The DF controls the mode for scanning of the string as stated in the case of MOVSB instruction. Whenever a match to the mention operand is found in string, execution stops and the zero flag is goes set. If no match is found, the zero flag is reset. The REPNE prefix is utilized with the SCAS instruction. The counters and pointers are updated automatically, until a match is found. Following string of instructions elaborates the use of SCAS instruction.

Example :

1987_SCAS.jpg

This string of instructions finds out, if contains WORD. If the WORD is found in the word string, before register CX becomes zero, the ZF is set, or else the ZF is reset. The scanning will continue until a match is found. Once a match is establish, the execution of the programme furtherproceeds.


Related Discussions:- Scas-string manipulation instruction-microprocessor

Eax and ax register, MyLocation SDWORD 14 TheTest        SDWORD 8     mov ...

MyLocation SDWORD 14 TheTest        SDWORD 8     mov    eax,MyLocation     mov    ebx,TheTest     neg     eax,ebx     sub     eax,ebx Show exactly what lives in eax after executi

Project ideas, can u please give me ideas on Assembly Language Projects usi...

can u please give me ideas on Assembly Language Projects using Nasm

Average of odd numbers, write an assembly language program to find average ...

write an assembly language program to find average of odd numbers from an array of 8 bit numbers

Segmentation, segmentation and overlapping in assemble language

segmentation and overlapping in assemble language

Ret-unconditional branch instruction-microprocessor, RET : Return from the...

RET : Return from the Procedure:- At each CALL instruction, the register IP and register CS of the next instruction is pushed to stack, before the control is transferred to the

Prepare the assembly code sequence, Problem (a) Prepare the assembly c...

Problem (a) Prepare the assembly code sequence for each of the four styles (accumulator, memory-memory, stack, load/store) of machine for the code fragment: A = B + C;

Fourth generation microprocessor, Fourth  Generation Microprocessor : T...

Fourth  Generation Microprocessor : The single chip 32-bit microprocessor was introduced in 1981 by Intel as iAPX 432. The other 4th generation  microprocessors  were;  Hewlett

Sub-arithmetic instruction-microprocessor, SUB: Subtract :- The subtract in...

SUB: Subtract :- The subtract instruction subtracts the source operand from destination operand and result is left in the destination operand. Source operand might be memory locati

Hand shaking-microprocessor, Hand shaking : Handshaking, or 2-way hand...

Hand shaking : Handshaking, or 2-way handshaking, is 1 type of strobe operation. It typically involves 2 handshaking lines: an output line to denote when the board is ready an

ISBN CHECK, How do i convert a asci number to numerals?

How do i convert a asci number to numerals?

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd