Below is a program block written in ARM Assembly

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

Below is a program block written in ARM Assembly. Since initially PC = 0x2000, Stack pointer sp = 0x400 (no data in the stack memory and shown next), what are the LR and SP values when PC = 0x2028 (when the corresponding row is executed)?

Aşağıda ARM Assembly ile yazılmış bir program bloğu görülmektedir. Başlangıçta PC = 0x2000, Stack pointer sp = 0x400 (stack memoryde hiç veri yoktur ve yanda gösterilmektedir), olduğuna göre, PC = 0x2028 değerine eşit olduğunda (ilgili satır
çalıştırıldığında) LR ve SP değerleri nedir?
Memory
Address
Program (Instructions)
Stack Memory
Ox400
OX3FC
OX3F8
Ox2000
Ox2004
MOV RO,#2
SP-->
BL fun1
Ox2008
B ENDL
LBL1 push (LR)
OX3F4
Ox200C
OX3F0
OX3EC
Ox3E8
Ox2010
MUL RO, RO
Ox2014
ADD RO, #1
Ox2018
BL LBL2
Ox201C
POP (PC)
OX3E4
Ox2020
LBL2 push (LR)
Ox 3E0
Ox2024
MUL RO,RO
OX3DC
Ox2028
ADD RO, #1
OX3D8
Ox202C
BL LBL3
OX3D4
Ox2030
POP (PC)
OX3D0
Ox2034 LBL3 push (LR}
OX3CC
OX3C8
Ox3C4
Ox2038
ADD RO, #1
РОP (РC)
fun1 PUSH (LR}
Ox203C
Ox2040
Ox3C0
Ox2044
BL LBL1
OX3BC
Ox3B8
Ox2048
POP (LR}
Ox204C
BX LR
Ox 3B4
Ox2050 ENDL
Ox3B0
Lütfen birini seçin:
O A. LR = Ox202C,
SP = 0x408
O B. LR = Ox2048,
SP = 0X3F0
O C. LR = Ox2008,
SP = 0X3F8
O D. LR = 0x201C,
SP = 0x404
O E. LR = 0x201C,
SP = 0X3F4
Transcribed Image Text:Aşağıda ARM Assembly ile yazılmış bir program bloğu görülmektedir. Başlangıçta PC = 0x2000, Stack pointer sp = 0x400 (stack memoryde hiç veri yoktur ve yanda gösterilmektedir), olduğuna göre, PC = 0x2028 değerine eşit olduğunda (ilgili satır çalıştırıldığında) LR ve SP değerleri nedir? Memory Address Program (Instructions) Stack Memory Ox400 OX3FC OX3F8 Ox2000 Ox2004 MOV RO,#2 SP--> BL fun1 Ox2008 B ENDL LBL1 push (LR) OX3F4 Ox200C OX3F0 OX3EC Ox3E8 Ox2010 MUL RO, RO Ox2014 ADD RO, #1 Ox2018 BL LBL2 Ox201C POP (PC) OX3E4 Ox2020 LBL2 push (LR) Ox 3E0 Ox2024 MUL RO,RO OX3DC Ox2028 ADD RO, #1 OX3D8 Ox202C BL LBL3 OX3D4 Ox2030 POP (PC) OX3D0 Ox2034 LBL3 push (LR} OX3CC OX3C8 Ox3C4 Ox2038 ADD RO, #1 РОP (РC) fun1 PUSH (LR} Ox203C Ox2040 Ox3C0 Ox2044 BL LBL1 OX3BC Ox3B8 Ox2048 POP (LR} Ox204C BX LR Ox 3B4 Ox2050 ENDL Ox3B0 Lütfen birini seçin: O A. LR = Ox202C, SP = 0x408 O B. LR = Ox2048, SP = 0X3F0 O C. LR = Ox2008, SP = 0X3F8 O D. LR = 0x201C, SP = 0x404 O E. LR = 0x201C, SP = 0X3F4
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY