Question

1.  Assume that the Instruction Pointer, EIP, contains 17510 and the assembly language representation of the instruction...

1.  Assume that the Instruction Pointer, EIP, contains 17510 and the assembly language representation of the instruction in memory at address 17510 is JAE 136. If the flags are currently CF=0, ZF=0 and SF=0 what is the value of the EIP after the instruction executes?

2.

Assume that the instruction pointer, EIP, initially contains 4910 and the assembly language representation of the instructions in memory starting at address 4910 is

Instruction Address Instruction
49 OR BL, 0x34
50 JE 79

Before the instruction sequence is executed, the flags are CF=1, ZF=0 and SF=1 and the Registers have the values AL=0x37, BL=0xEC CL=0xB8 and DL=0x99. What is the value of the instruction pointer after the sequence executes?

3. Assume that before the instruction is executed, the flags are CF=1, ZF=1 and SF=1 and the Registers have the values AL=0xAF, BL=0x75 CL=0x48 and DL=0xEA.

What are the values of the flags after the instruction ADD AL, 0xF4 executes?

CF =

ZF =

SF =

4.  Assume that the Instruction Pointer, EIP, contains 17510 and the assembly language representation of the instruction in memory at address 17510 is JAE 136. If the flags are currently CF=0, ZF=0 and SF=0 what is the value of the EIP after the instruction executes?

Homework Answers

Answer #1

1.

EIP is the Instruction Pointer Register which speaks to the address of the instruction to be executed straightaway.

Right now, EIP = 175 10

The current flag values are CF = 0, ZF = 0 and SF = 0

where CF shows the carry Flag, ZF demonstrates the Zero Flag and SF indicates the Sign Flag.

The instruction to be executed is JAE 136

where JAE shows the Jump on Above or Equal to. This instruction performs the bounce if the carry flag is set to 0. for example assuming CF = 0, the hop is taken, else the hop won't be taken.

According to the status of the flags, CF = 0 and thus the jump is taken to the address 136. Since the following instruction to be executed is at address 136, EIP will be stacked with address 136.

Subsequently EIP = 136.

4.

EIP is the Instruction Pointer Register which speaks to the address of the instruction to be executed straightaway.

Right now, EIP = 175 10

The current flag values are CF = 0, ZF = 0 and SF = 0

where CF shows the carry Flag, ZF demonstrates the Zero Flag and SF indicates the Sign Flag.

The instruction to be executed is JAE 136

where JAE shows the Jump on Above or Equal to. This instruction performs the bounce if the carry flag is set to 0. for example assuming CF = 0, the hop is taken, else the hop won't be taken.

According to the status of the flags, CF = 0 and thus the jump is taken to the address 136. Since the following instruction to be executed is at address 136, EIP will be stacked with address 136.

Subsequently EIP = 136.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
in assembly 1. Real mode allows access to memory below which memory address? 2. Under real...
in assembly 1. Real mode allows access to memory below which memory address? 2. Under real and protected mode, the far jump modifies the current instruction address by changing which register or registers? 3. Under real and protected mode, the near jump modifies the current instruction address by changing which register or registers? 4. Under real mode, briefly explain what happens when the PUSH BX instruction executes. Make sure to show where BH and BL are stored. Assume that initially...
(MIPS Assembly Language): Assume the following piece of MIPS code: label1: .text 0x4000fc lui $t0, 1022...
(MIPS Assembly Language): Assume the following piece of MIPS code: label1: .text 0x4000fc lui $t0, 1022 ori $t0, $t0, 2048 srl $t1, $t0, 18 sw $t0, 101($t1) slti $t2, $t1, 5 beq $t2, $0, label3 label2:... ... label3:... a) The code modifies a word in memory at the following address (circle one): (i) 1022 (ii) 101 (iii) 5 (iv) 10220000 (v) Other (provide your own answer): _________________ b) The following value is stored in memory (circle one): (i) 0x17 (ii)...
This is a homework assignment for Computer Architecture and some question use MIPS Assembly language. 1.    ...
This is a homework assignment for Computer Architecture and some question use MIPS Assembly language. 1.     In the following MIPS assembly code, translate all the instructions to their corresponding machine code in hexadecimal format. This code is stored in the memory from address 0x1fff0000. Loop: sw $t1, 4($s0)        addi $t1, $t1, -1    sll $t1, $t1, 2        bne $t1, $s5, Exit    addi $s0, $s0, 4          j Loop Exit: … 2.     Find the MIPS...
Write a sequence of two instructions that copies bits 0-5 from AL to bits 0-5 in...
Write a sequence of two instructions that copies bits 0-5 from AL to bits 0-5 in BL. Bits 6-7 in BL should be cleared, and AL should be unchanged             Mov al, bl       And 00111111, bl       Write a sequence of two instructions that copies the integer in bits 4-7 from AL register into bits 0-3 of the BL register. Upper 4 bits of AL and BL will be cleared             Shr al, 4       Mov bl,...
Can i get the answer to these questions in detail explaining how you go to the...
Can i get the answer to these questions in detail explaining how you go to the solution 1.Convert to/from Hex (0) 2.Octal Binary Unsigned/ 2’s complement 3.Understand how to shift and rotate. 4.Understand the relationship between shifting and multiplication/division 5.Be able to recognize and use the following gates: AND OR NOT NAND NOR XOR 6.Understand how a half adder works Given a logical statement ((A OR B) AND NOT(C OR A)) show the gates. 7.What is the difference between an...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT