1 / 26

COMP541 Completing the MIPS Datapath

2. Datapath Lab. Last Friday's lab: Included thisNeed more: also memory/control. 3. Next few labs. March 30: lw and sw and branchingApril 6: Complete CPU (Holiday?)Add VGA, keyboard/joystick. 4. Next Lab. Implement the lw and sw instructions.The address for lw/sw generated by ALUFormat sw $r1, 100($r2)Store contents of register 1 toaddress $r2 100Implement branch instructions.

lulu
Download Presentation

COMP541 Completing the MIPS Datapath

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


    1. 1 COMP541 Completing the MIPS Datapath Montek Singh Mar 27, 2007

    2. 2 Datapath Lab Last Friday’s lab: Included this Need more: also memory/control

    3. 3 Next few labs March 30: lw and sw and branching April 6: Complete CPU (Holiday?) Add VGA, keyboard/joystick

    4. 4 Next Lab Implement the lw and sw instructions. The address for lw/sw generated by ALU Format sw $r1, 100($r2) Store contents of register 1 to address $r2 + 100 Implement branch instructions

    5. 5 Store Word Easier Just disable writing to register Set an address and write to memory Could use second memory port and write on same cycle as next instruction Let’s look at block diagram…

    6. 6 Block Diagram (just lw/sw)

    7. 7 R-Type and lw/sw

    8. 8 Load Word Need to determine memory address Using ALU Then need to read memory and write to register

    9. 9 Careful If you use one memory port, your instruction will disappear You could use the other memory port Could add an instruction register More complex control Harvard Architecture another possibility

    10. 10 Sign Extension Don’t get sidetracked into complexity Just extend value of bit 15 to upper 16 bits How?

    11. 11 Branching Add beq (branch on equal) That should give enough breadth to actually write full programs

    12. 12 Resulting MIPS Datapath

    13. 13 With Control

    14. 14 Memory Addressing Byte address or word address?

    15. 15 The MIPS Datapath

    16. 16 Expanding Memory Block First let’s look in detail at data memory block See how to add block memories Add I/O

    17. 17 Memory Block Signals

    18. 18 Using 2 Block RAMs Illustration from book Let’s work it out for Block RAMs Specs next

    19. 19 Block RAM Specs Try 2 256x16

    20. 20 Adding More Memory Illustration from text Could add 2 more block RAMs to increase mem to 512 words

    21. 21 Memory Map Refers to how physical memory is populated In our example, memory from 0 to 511 It’s in two blocks, but that’s invisible to programmer

    22. 22 Another Portion of Memory Let’s see how to add a block of x8 character memory for the VGA Need to make 24 bits be zero

    23. 23 Memory Map

    24. 24 Adding I/O Look at memory-mapped I/O Conceptually like this

    25. 25 In Reality Isolated from CPU On standard buses PCI Ours will be simpler Just memory addresses

    26. 26 Later You’ll add joystick or keyboard (or both) into memory locations that you can read

    27. 27 How Does Processor Begin? One way is to initialize PC to 0 Make sure to have instructions there Real computers have flash memory to boot CPU or go to configuration utility On (very) old computers had to enter boot program on front panel

More Related