Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1 point In ARM Cortex-M instructions, the second source operand can be in different formats. Which of the following instructions is NOT allowed? * ANDS

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribed

1 point In ARM Cortex-M instructions, the second source operand can be in different formats. Which of the following instructions is NOT allowed? * ANDS RO, R1, R2, ROR #5 SUBS RO, R1, #12345678 MULS RO, R1, R2, LSL #5 LSLS RO, R1, #7 1 point The second source operand of an instruction can optionally use a barrel shifter. In the following instruction "ADDS ro, r1, r2, LSL #4", the Barrel shifter takes four clock cycles to shift register r2. This is because it takes on clock cycle to shift a register left by one bit. It requires 4 cycles to shift a register left by four bits. * True False 1 point Regarding the rotation (also called circular shift), which of the following statement is wrong? * ARM Cortex-M doesn't provide any instruction to rotate left. This is because rotate left n bits can be achieved by rotating right 32-n bits. We can implement rotation operations in the C language. However, there are no rotation operators in C. The Barrel shifter supports rotation ROR (Rotate Right) and RRX (Rotate Right with Extend). O The following operation is allowed: RRX RO, R1, #2. 1 point Assume RO = Ox0000_0002, what is the value of R1 after executing the following instruction? ADD R1, RO, RO, LSL #2 * R1 = 0x0000_0010 R1 = 0x0000_0006 R1 = 0x0000_0004 R1 = 0x0000_000A 1 point Suppose we need to toggle bit 15 of register RO. Which of the following code is wrong? MOVS R1 #1; EOR RO, RO, R1 LSL #15 MOV R1 #1; MOVS R1, R1 LSL #15; EOR RO, RO, R1 MOVS R1 #1; LSL R1, R1, #15; EORS RO, RO, R1 MOV R1 #1; MVN R1, R1 LSL #15; AND RO, RO, R1 1 point For ARM Cortex-M, there are two add instructions, one for adding two signed integers, and the other for adding two unsigned integers. * True False 1 point What are the values of the NZCV bit flags in the Program Status Register (PSR) after the following instruction completes? "ORRS RO, R2, R1, LSR #1". Assuming R1 = OxFFFF_FFFF and R2 = Ox0000_0020. * O N = 1, Z = 0, C = 1, V = 0 N = 0, Z = 0, C = 0, V = 1 N = 0, Z = 0, C = 1, V not changed. O N = 0, Z = 0, C not changed, V not changed * Which of the following operations cannot change the carry flag? 1 point A shift or rotate operation A load or store operation An add operation A subtract operation

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

Practical Database Programming With Visual C# .NET

Authors: Ying Bai

1st Edition

0470467274, 978-0470467275

More Books

Students also viewed these Databases questions

Question

=+What sanctions are available to employers

Answered: 1 week ago

Question

=+ If strikes occur, are they legally regulated?

Answered: 1 week ago

Question

=+industrial action Under what circumstances can unions strike?

Answered: 1 week ago