Question

We are using the Kip Irvine Assembly Language for x86 Processors. The programming language is Assembly,...

We are using the Kip Irvine Assembly Language for x86 Processors. The programming language is Assembly, and we are using visual studio community. Please specify any questions.

Directions

Declare an array of 60 uninitialized unsigned doubleword values. Create another array of 60 unsigned doublewords, initialized to ‘abcd’. Look at these arrays in the memory window and note how they are stored. (Intel architecture uses little - endian order)

ATTEMPT ONLY IF YOU KNOW OTHERWISE I WILL DOWNVOTE.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

.386
.model flat,stdcall
.stack 4096
ExitProcess proto,dwExitCode:dword
.data
array dword 1,2,3,4,5,6,7,8
.code
main proc
mov esi, OFFSET array
mov ecx, LENGTHOF array -1

myLoop:

MOV eax,[esi]
XCHG eax,[esi+3]
MOV [esi],eax

add esi, TYPE array
add esi, TYPE array

loop myLoop

invoke ExitProcess,0
main endp
end main

Add a comment
Know the answer?
Add Answer to:
We are using the Kip Irvine Assembly Language for x86 Processors. The programming language is Assembly,...
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. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • This is a question from Assembly Language for x86 7th Edition by Kip Irvine, but the...

    This is a question from Assembly Language for x86 7th Edition by Kip Irvine, but the solution is not there. Programming exercise 12.7 #2. The code must be in assembly language for Intel using Kip Irvine library. An example of the source code would be: INCLUDE Irvine32.inc .code main PROC mov ax,4000h mov bx,1000h mov cx,1500h sub ax,bx sub ax,cx call DumpRegs exit main ENDP END main Question: Write a procedure that receives a single-precision floating-point binary value and displays...

  • Assembly language x86 processors in c++ starting with asm_ 4 The Sheraton Hotel in Irvine is...

    Assembly language x86 processors in c++ starting with asm_ 4 The Sheraton Hotel in Irvine is a 16 floor building. Suppose each bits of AX register represent one floor (the right most bit is representing the first floor). Ten people got into the elevator on the first floor and each pressed a random floor number between 2 and 16 (some random numbers may be the same which indicates more than one person will get off at the same floor). Write...

  • Assembly Language For x86 Processors 7th edition When you write programs to solve the programming exercises,...

    Assembly Language For x86 Processors 7th edition When you write programs to solve the programming exercises, use multiple procedures when possible. Follow the style and naming conventions used in this book. Use explanatory comments in your programs at the beginning of each procedure and next to nontrivial statements. Random Strings Create a procedure that generates a random string of length L, containing all capital letters. When calling the procedure, pass the value of L in EAX, and pass a pointer...

  • this is assembly language for x-86 processors using microsoft visual studio Create a procedure named FindThrees...

    this is assembly language for x-86 processors using microsoft visual studio Create a procedure named FindThrees that returns 1 if an array has three consecutive values of 3 somewhere in the array. Otherwise, return 0. The procedure’s input parameter list contains a pointer to the array and the array’s size. Use the PROC directive with a parameter list when declaring the procedure. Preserve all registers (except EAX) that are modified by the procedure. Write a test program that calls FindThrees...

  • Convert this C++ program to x86 assembly language using the Irvine library: #include <iostream> unsigned int...

    Convert this C++ program to x86 assembly language using the Irvine library: #include <iostream> unsigned int x; unsigned int c; unsigned int result; // f(x) = 8x + c // Make sure to push and pop all necessary registers to the stack to // ensure only the EAX register is modified upon return from the function unsigned int Equation(unsigned int x, unsigned int c) { // You CANNOT use the mul or imul operations to perform the multiplication return (8...

  • MASM Assembly Language for x86 Processors: Given the following array declaration: .data matrix DWORD 50 DUP(10...

    MASM Assembly Language for x86 Processors: Given the following array declaration: .data matrix DWORD 50 DUP(10 DUP(?)) If matrix[0][0] is the 0th sequentially stored BYTE in memory, which sequentially stored BYTE is the first byte corresponding to matrix[14][2]? (in decimal) Please expplain how you got the answer, so I can answer other questions like this! Thank you

  • X86 Assembly language lab: TITLE Lab 3: assembly language fundamentals               ;;;;; Q1: Don't...

    X86 Assembly language lab: TITLE Lab 3: assembly language fundamentals               ;;;;; Q1: Don't forget to document your program            ; Name:Yuyan Wang ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;; Answer each question below by writing code at the APPROPRIATE places in the file. ;;;;; Hint: the appropriate place is not always right below the question. ;;;;; Q2: Write the directive to bring in the IO library           ;;;;; Q3: Create a constant called MAX and initialize it to 150...

  • Assembly Language Programming Assignment program must be in: MASM assembly language / x86 architecture / irvine...

    Assembly Language Programming Assignment program must be in: MASM assembly language / x86 architecture / irvine library procedures Objectives: 1. using register indirect addressing 2. passing parameters 3. generating “random” numbers 4. working with arrays Description: Write and test a MASM program to perform the following tasks: 1. Introduce the program. 2. Generate ARRAYSIZE random integers in the range [LO = 10 .. HI = 29], storing them in consecutive elements of an array. ARRAYSIZE should be set to 200....

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT