Consider the following three machine instructions, whichappear in memory startin
ID: 3609137 • Letter: C
Question
Consider the following three machine instructions, whichappear in memory starting at the address 0x00400000. address (in hex) contents (in hex) 0x00400000 0x12080002 0x00400004 0x3C11FFFF 0x00400008 0x08100004(a) Disassemble" the instructions; that is, give an assemblylanguage program segment that would be translated into the given machinelanguage.
(b) You may use numeric rather than symbolic registernames.
(c) Handle branches and jumps specially; where you wouldnormally have a label, provide instead a hexadecimal byte address.
these question are very confusing for me. Greatlyappreciated! Confused with the whole address stuff. pleasehelp. Consider the following three machine instructions, whichappear in memory starting at the address 0x00400000. address (in hex) contents (in hex) 0x00400000 0x12080002 0x00400004 0x3C11FFFF 0x00400008 0x08100004
(a) Disassemble" the instructions; that is, give an assemblylanguage program segment that would be translated into the given machinelanguage.
(b) You may use numeric rather than symbolic registernames.
(c) Handle branches and jumps specially; where you wouldnormally have a label, provide instead a hexadecimal byte address.
these question are very confusing for me. Greatlyappreciated! Confused with the whole address stuff. pleasehelp.
Explanation / Answer
Dear, Given inatructions are, Contents Address 0x12080002 0x00400000 0x3C11FFFF 0x00400004 0x08100004 0x00400008 For the given hexa instruction the equivalent machinecode is, 0x12080002 - Incerement Index Register INX and store theresultant value in the address location 0x00400000 0x3C11FFFF -The value in the stored index register is compared with accumlatorand the result is stored in the address location 0x00400004 Themachine instructions are, CBA and STX 0x08100004 -Now the Accumlator is incremented and stored in address location0x00400008 Themachine instructions are, INX " I hope this will help you " 0x3C11FFFF 0x00400004 0x08100004 0x00400008 For the given hexa instruction the equivalent machinecode is, 0x12080002 - Incerement Index Register INX and store theresultant value in the address location 0x00400000 0x3C11FFFF -The value in the stored index register is compared with accumlatorand the result is stored in the address location 0x00400004 Themachine instructions are, CBA and STX 0x08100004 -Now the Accumlator is incremented and stored in address location0x00400008 Themachine instructions are, INX " I hope this will help you "Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.