next up previous contents
Next: Address generation Up: Processor Memory Unit Previous: Processor Memory Unit

Adding new instructions to the memory unit

Source files: src/Processor/memunit.cc

Header files: incl/Processor/memory.h

The function AddToMemorySystem is called to add new instructions to the memory unit. This function first initializes some fields of the instance. If this instruction is a store, it is added to the list of stores which have not yet had their addresses generated (called ambig_st_tags). For SC and PC, this instruction is added to the unified memory unit queue, MemQueue. For RC, this instruction is inserted into either the LoadQueue or StoreQueue as appropriate. The LoadQueue and StoreQueue are currently used only as a simulator abstraction - the memory unit is thought of as a unified whole, rather than two split parts.

If this instance does not have any outstanding address dependences (i.e. addrdep is clear, as discussed in Section 10), it is sent on to the address generation unit by calling CalculateAddress.



Vijay Sadananda Pai
Thu Aug 7 14:18:56 CDT 1997