Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can anyone help me with the second part? I do not know how to do it. Please someone explain to me. I want to understand

Can anyone help me with the second part? I do not know how to do it. Please someone explain to me. I want to understand how this problem works. This is assembly language. I did the first part. I only need help with the second part. Thank you.

1. Assume that you are given values in eax, ebx, ecx. Write an assembly code that does the following: eax = (ecx + edx ) - (eax + ebx) 2. Write a piece of code that copies the number inside al to ch. Example: Assume that Initially eax = 0x15DBCB19. At the end of your code ecx = 0x00001900. Your code must be as efficient as possible. 3. You are given eax = 0x5. Write one line of code in assembly to Zero eax. Don't use Sub instruction and you must use hex numbers only as immediate numbers. 4. Implement the following arithmetic expression in assembly language: EBX = var1 - var2 - 9 + var3 // size of variables, 4 bytes each 5. Write a piece of code in assembly that implements the following C++ statement num1 = num2 = 4; // x and y are of size word (2 bytes) 6. Write a piece of code that implements the following C++ statements d = 'w'; // a ,d,b are of size byte. a = d + 1; b = a + 2;

Part two:(8 points) Open hello.asm. Before the exit line of code, add the line of code: mov ebx, -20 add ebx, 1 Save and build the project. Set a breakpoint after the add line that you just added. Run to the breakpoint Open the debug window to see all the registers. Select Step Into (F11) to run the add line of code Show what values are in the following registers: BL: BH: BX: EBX

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database And Expert Systems Applications 22nd International Conference Dexa 2011 Toulouse France August/September 2011 Proceedings Part 1 Lncs 6860

Authors: Abdelkader Hameurlain ,Stephen W. Liddle ,Klaus-Dieter Schewe ,Xiaofang Zhou

2011th Edition

3642230873, 978-3642230875

More Books

Students also viewed these Databases questions

Question

U11 Informing Industry: Publicizing Contract Actions 317

Answered: 1 week ago

Question

Explain how cultural differences affect business communication.

Answered: 1 week ago

Question

List and explain the goals of business communication.

Answered: 1 week ago