Ruby: Machine Type missing in MOESI CMP directory protocol
In certain actions of the L1 cache controller, while creating an outgoing message, the machine type was not being set. This results in a segmentation fault when trace is collected. Joseph Pusudesris provided his patch for fixing this issue.
This commit is contained in:
parent
293ccb7037
commit
77eed184f5
1 changed files with 11 additions and 0 deletions
|
@ -399,6 +399,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceRequestType:GETS;
|
out_msg.Type := CoherenceRequestType:GETS;
|
||||||
out_msg.Requestor := machineID;
|
out_msg.Requestor := machineID;
|
||||||
|
out_msg.RequestorMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.MessageSize := MessageSizeType:Request_Control;
|
out_msg.MessageSize := MessageSizeType:Request_Control;
|
||||||
|
@ -443,6 +444,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceRequestType:PUTO;
|
out_msg.Type := CoherenceRequestType:PUTO;
|
||||||
out_msg.Requestor := machineID;
|
out_msg.Requestor := machineID;
|
||||||
|
out_msg.RequestorMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.MessageSize := MessageSizeType:Writeback_Control;
|
out_msg.MessageSize := MessageSizeType:Writeback_Control;
|
||||||
|
@ -455,6 +457,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceRequestType:PUTS;
|
out_msg.Type := CoherenceRequestType:PUTS;
|
||||||
out_msg.Requestor := machineID;
|
out_msg.Requestor := machineID;
|
||||||
|
out_msg.RequestorMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.MessageSize := MessageSizeType:Writeback_Control;
|
out_msg.MessageSize := MessageSizeType:Writeback_Control;
|
||||||
|
@ -469,6 +472,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA;
|
out_msg.Type := CoherenceResponseType:DATA;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.DataBlk := cache_entry.DataBlk;
|
out_msg.DataBlk := cache_entry.DataBlk;
|
||||||
|
@ -484,6 +488,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA;
|
out_msg.Type := CoherenceResponseType:DATA;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(in_msg.Requestor);
|
out_msg.Destination.add(in_msg.Requestor);
|
||||||
out_msg.DataBlk := cache_entry.DataBlk;
|
out_msg.DataBlk := cache_entry.DataBlk;
|
||||||
// out_msg.Dirty := cache_entry.Dirty;
|
// out_msg.Dirty := cache_entry.Dirty;
|
||||||
|
@ -502,6 +507,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA;
|
out_msg.Type := CoherenceResponseType:DATA;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.DataBlk := cache_entry.DataBlk;
|
out_msg.DataBlk := cache_entry.DataBlk;
|
||||||
|
@ -580,6 +586,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:UNBLOCK;
|
out_msg.Type := CoherenceResponseType:UNBLOCK;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.MessageSize := MessageSizeType:Unblock_Control;
|
out_msg.MessageSize := MessageSizeType:Unblock_Control;
|
||||||
|
@ -678,6 +685,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA;
|
out_msg.Type := CoherenceResponseType:DATA;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(in_msg.Requestor);
|
out_msg.Destination.add(in_msg.Requestor);
|
||||||
out_msg.DataBlk := tbe.DataBlk;
|
out_msg.DataBlk := tbe.DataBlk;
|
||||||
// out_msg.Dirty := tbe.Dirty;
|
// out_msg.Dirty := tbe.Dirty;
|
||||||
|
@ -691,6 +699,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA;
|
out_msg.Type := CoherenceResponseType:DATA;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.DataBlk := tbe.DataBlk;
|
out_msg.DataBlk := tbe.DataBlk;
|
||||||
|
@ -711,6 +720,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA_EXCLUSIVE;
|
out_msg.Type := CoherenceResponseType:DATA_EXCLUSIVE;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(in_msg.Requestor);
|
out_msg.Destination.add(in_msg.Requestor);
|
||||||
out_msg.DataBlk := tbe.DataBlk;
|
out_msg.DataBlk := tbe.DataBlk;
|
||||||
out_msg.Dirty := tbe.Dirty;
|
out_msg.Dirty := tbe.Dirty;
|
||||||
|
@ -723,6 +733,7 @@ machine(L1Cache, "Directory protocol")
|
||||||
out_msg.Address := address;
|
out_msg.Address := address;
|
||||||
out_msg.Type := CoherenceResponseType:DATA_EXCLUSIVE;
|
out_msg.Type := CoherenceResponseType:DATA_EXCLUSIVE;
|
||||||
out_msg.Sender := machineID;
|
out_msg.Sender := machineID;
|
||||||
|
out_msg.SenderMachine := MachineType:L1Cache;
|
||||||
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
out_msg.Destination.add(mapAddressToRange(address, MachineType:L2Cache,
|
||||||
l2_select_low_bit, l2_select_num_bits));
|
l2_select_low_bit, l2_select_num_bits));
|
||||||
out_msg.DataBlk := tbe.DataBlk;
|
out_msg.DataBlk := tbe.DataBlk;
|
||||||
|
|
Loading…
Reference in a new issue