Re: [Gems-users] processor id in ruby


Date: Thu, 31 Mar 2005 09:03:12 -0600 (CST)
From: Mike Marty <mikem@xxxxxxxxxxx>
Subject: Re: [Gems-users] processor id in ruby
> Is there a way in ruby to find which processor a request came from? I was trying
> to do that but figured that even CacheMsg does not have that field.

Some protocolts have a Requestor field in the Request message.  This is of
type "MachineID" which identifies both the component (L1Cache, L2Cache,
Directory, etc) and the number.  What you want is to convert MachineID, of
component L1Cache, to simply a number that denotes processor number.  You
can do this with the following method defined in
RubySlicc_ComponentMapping.sm:

NodeID L1CacheMachIDToProcessorNum(MachineID machID);

NodeID is typedefed to an int

> For all CMP protocols L2 is essentially shared or we can have a distributed
> cache too?

The 3 CMP protocols use a shared L2 by default.  If you want private L2s,
you will need to change the mapping functions used.  For example, change
this method also defined in RubySlicc_ComponentMapping.sm and implemented
in RubySlicc_ComponentMapping.h:

MachineID map_L1CacheMachId_to_L2Cache(Address addr, MachineID
L1CacheMachId);

This is what some of the CMP protocols use to set the destination of a
miss request and writeback.

> I found that number of directories per chip was set to be equal to number of
> processors per chip. Would things still work if there is only 1 directory per chip?
>

It should work.

--Mike

[← Prev in Thread] Current Thread [Next in Thread→]