Question: Machine Language Programming [problems 7.27 & 7.28) and the SML system, the first two digits refer to the Op.code and the last two digits to

 Machine Language Programming [problems 7.27 & 7.28) and the SML system,

Machine Language Programming [problems 7.27 & 7.28) and the SML system, the first two digits refer to the Op.code and the last two digits to the operand memory location. (From page 327/328) The Op.codes are: READ 10; WRITE 11;LOAD 20; STORE 21; ADD 30; SUBTRACT 31; DIVIDE 32; MULTIPLY 33; BRANCH 40; BRANCHNEG 41; BRANCHZERO 42; HALT 43; In the following functional machine language program, starting at memory 00. .a) To which location the program loops at the execution of the Halt instruction? .a) Ans _______ .b) After the program is run starting from location 00, entered A and B values are 43 and 12. What are the final contents of the Accumulator, Instruction counter and instruction register? .b)Accumulator ______ Instruction counter ______ Instruction register________ .c) After the program is run, what is output? .c) Output________ .d) The program is rerun with A and B values as 39 and 77. What is output? .d)Output_________ .e) What is accomplished in the program? (Output sum of A and B; Output difference of A and B; Output smaller of A and B; None of these (which))? .e) Ans____________

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!