FIT1047 Lab Week 4 Solution PDF

Title FIT1047 Lab Week 4 Solution
Author justhelpingout lmao
Course Introduction to Computers, Networks and Security
Institution Monash University
Pages 3
File Size 70.4 KB
File Type PDF
Total Downloads 82
Total Views 136

Summary

Download FIT1047 Lab Week 4 Solution PDF


Description

FIT1047 Tutorial 4 – Sample Solution Topics • Register Transfer Language • Memory addressing • Programming MARIE assembly code

Instructions The tasks are supposed to be done in groups of two or three students. You will need the MARIE simulator for this assignment.

Task 1: Conditionals A conditional statement allows the flow of a program to depend on data. In a highlevel programming language, this is typically achieved using if-then-else statements such as the following (this is Python syntax): if X == Y: X = X + Y else: Y = Y + x Implement this piece of code using MARIE assembly. Make use of labels!

Task 2: Extending the instruction set We are going to extend the MARIE instruction set by the following instruction: • SkipIfGreater X skips the next instruction if the value at memory address X is greater than the value in AC. Give the RTL steps needed to implement the instruction. MAR...


Similar Free PDFs