summaryrefslogtreecommitdiff
path: root/src/mem/DRAMCtrl.py
diff options
context:
space:
mode:
authorWendy Elsasser <wendy.elsasser@arm.com>2014-09-20 17:17:57 -0400
committerWendy Elsasser <wendy.elsasser@arm.com>2014-09-20 17:17:57 -0400
commitb6ecfe918364ce4b7df0f95590b483100bbfcba9 (patch)
treeaae499f62e89e9b15bc23a1258f8a4aa58378eb6 /src/mem/DRAMCtrl.py
parenta384525355c37f8776e03c78e12279c38c5c3097 (diff)
downloadgem5-b6ecfe918364ce4b7df0f95590b483100bbfcba9.tar.xz
mem: Add memory rank-to-rank delay
Add the following delay to the DRAM controller: - tCS : Different rank bus turnaround delay This will be applied for 1) read-to-read, 2) write-to-write, 3) write-to-read, and 4) read-to-write command sequences, where the new command accesses a different rank than the previous burst. The delay defaults to 2*tCK for each defined memory class. Note that this does not correspond to one particular timing constraint, but is a way of modelling all the associated constraints. The DRAM controller has some minor changes to prioritize commands to the same rank. This prioritization will only occur when the command stream is not switching from a read to write or vice versa (in the case of switching we have a gap in any case). To prioritize commands to the same rank, the model will determine if there are any commands queued (same type) to the same rank as the previous command. This check will ensure that the 'same rank' command will be able to execute without adding bubbles to the command flow, e.g. any ACT delay requirements can be done under the hoods, allowing the burst to issue seamlessly.
Diffstat (limited to 'src/mem/DRAMCtrl.py')
-rw-r--r--src/mem/DRAMCtrl.py44
1 files changed, 34 insertions, 10 deletions
diff --git a/src/mem/DRAMCtrl.py b/src/mem/DRAMCtrl.py
index 8c573ca3a..b06b8e7eb 100644
--- a/src/mem/DRAMCtrl.py
+++ b/src/mem/DRAMCtrl.py
@@ -156,11 +156,17 @@ class DRAMCtrl(AbstractMemory):
# to be sent. It is 7.8 us for a 64ms refresh requirement
tREFI = Param.Latency("Refresh command interval")
- # write-to-read turn around penalty
- tWTR = Param.Latency("Write to read switching time")
+ # write-to-read, same rank turnaround penalty
+ tWTR = Param.Latency("Write to read, same rank switching time")
- # read-to-write turn around penalty, bus turnaround delay
- tRTW = Param.Latency("Read to write switching time")
+ # read-to-write, same rank turnaround penalty
+ tRTW = Param.Latency("Read to write, same rank switching time")
+
+ # rank-to-rank bus delay penalty
+ # this does not correlate to a memory timing parameter and encompasses:
+ # 1) RD-to-RD, 2) WR-to-WR, 3) RD-to-WR, and 4) WR-to-RD
+ # different rank bus delay
+ tCS = Param.Latency("Rank to rank switching time")
# minimum row activate to row activate delay time
tRRD = Param.Latency("ACT to ACT delay")
@@ -221,9 +227,12 @@ class DDR3_1600_x64(DRAMCtrl):
# Greater of 4 CK or 7.5 ns
tRTP = '7.5ns'
- # Default read-to-write bus around to 2 CK, @800 MHz = 2.5 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @800 MHz = 2.5 ns
tRTW = '2.5ns'
+ # Default different rank bus delay to 2 CK, @800 MHz = 2.5 ns
+ tCS = '2.5ns'
+
# <=85C, half for >85C
tREFI = '7.8us'
@@ -296,9 +305,12 @@ class DDR4_2400_x64(DRAMCtrl):
# Greater of 4 CK or 7.5 ns
tRTP = '7.5ns'
- # Default read-to-write bus around to 2 CK, @1200 MHz = 1.666 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @1200 MHz = 1.666 ns
tRTW = '1.666ns'
+ # Default different rank bus delay to 2 CK, @1200 MHz = 1.666 ns
+ tCS = '1.666ns'
+
# <=85C, half for >85C
tREFI = '7.8us'
@@ -353,9 +365,12 @@ class DDR3_1333_x64_DRAMSim2(DRAMCtrl):
# Greater of 4 CK or 7.5 ns, 4 CK @ 666.66 MHz = 6 ns
tWTR = '7.5ns'
- # Default read-to-write bus around to 2 CK, @666.66 MHz = 3 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @666.66 MHz = 3 ns
tRTW = '3ns'
+ # Default different rank bus delay to 2 CK, @666.66 MHz = 3 ns
+ tCS = '3ns'
+
tRRD = '6.0ns'
tXAW = '30ns'
@@ -416,9 +431,12 @@ class LPDDR2_S4_1066_x32(DRAMCtrl):
# Irrespective of speed grade, tWTR is 7.5 ns
tWTR = '7.5ns'
- # Default read-to-write bus around to 2 CK, @533 MHz = 3.75 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @533 MHz = 3.75 ns
tRTW = '3.75ns'
+ # Default different rank bus delay to 2 CK, @533 MHz = 3.75 ns
+ tCS = '3.75ns'
+
# Activate to activate irrespective of density and speed grade
tRRD = '10.0ns'
@@ -473,9 +491,12 @@ class WideIO_200_x128(DRAMCtrl):
# Greater of 2 CK or 15 ns, 2 CK @ 200 MHz = 10 ns
tWTR = '15ns'
- # Default read-to-write bus around to 2 CK, @200 MHz = 10 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @200 MHz = 10 ns
tRTW = '10ns'
+ # Default different rank bus delay to 2 CK, @200 MHz = 10 ns
+ tCS = '10ns'
+
# Activate to activate irrespective of density and speed grade
tRRD = '10.0ns'
@@ -536,9 +557,12 @@ class LPDDR3_1600_x32(DRAMCtrl):
# Irrespective of speed grade, tWTR is 7.5 ns
tWTR = '7.5ns'
- # Default read-to-write bus around to 2 CK, @800 MHz = 2.5 ns
+ # Default same rank rd-to-wr bus turnaround to 2 CK, @800 MHz = 2.5 ns
tRTW = '2.5ns'
+ # Default different rank bus delay to 2 CK, @800 MHz = 2.5 ns
+ tCS = '2.5ns'
+
# Activate to activate irrespective of density and speed grade
tRRD = '10.0ns'