Skip to content

Adds HBMCtrl#22

Open
aakahlow wants to merge 20 commits intomemctrl-restrfrom
hbmctrl-rest
Open

Adds HBMCtrl#22
aakahlow wants to merge 20 commits intomemctrl-restrfrom
hbmctrl-rest

Conversation

@aakahlow
Copy link
Contributor

@aakahlow aakahlow commented May 5, 2022

TODO: Add more description into commit messages

This PR adds hbm ctrl and other related interface changes required for HBM ctrl

Also, builds on top of the SimpleMemCtrl and MemCtrl change

@aakahlow aakahlow force-pushed the hbmctrl-rest branch 3 times, most recently from b0429e0 to 95d4ff2 Compare May 6, 2022 03:49
Copy link
Member

@powerjg powerjg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

writeQueue.resize(p.qos_priorities);

dram->setCtrl(this, commandWindow);
dram->setCtrl(this, commandWindow, 0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If default 0, no need to change

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Comment on lines +63 to +69
fatal_if(!ch0_int, "Memory controller must have ch0 interface");
fatal_if(!ch1_int, "Memory controller must have ch1 interface");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add something to make sure these interfaces are the same type?

aakahlow added 9 commits May 8, 2022 21:14
Change-Id: I1822f68aa962c27b0e2de175dda6a0857e78fce4
Change-Id: If0ffefec43a37fb3ba0fe96a69b8a616bd86d1b5
Change-Id: I3c751837ac3bd02d5941a54c23ee6d9660f0ad59
Change-Id: If4ab5274fce6f83a5a12a78e9fcd8bae2195c3bb
Change-Id: Iab46c6c4a19c1919ec817ce950b8475fc68b4777
Change-Id: I113f73337d80487acdcbe2815d0011e6f3116199
Change-Id: Iff8b219cc82b86b4f5c1f2ae92382e242dd4a039
Change-Id: I6f2fa14e28e3c1769710537c6b0ca5ef945bfa6f
Change-Id: I5e3647fb026e7a175cc3e6be87554cd4d7a34927
aakahlow added 7 commits May 9, 2022 15:50
Change-Id: I66bd138e4773c32c22156b877426fc73a8c593fa
Change-Id: Id34930d7f00250b1a3ddd4a7606d8300279387b8
Change-Id: I0cd62e1969544c46008d9b3f34661de57adaa703
Change-Id: If91f357821029397a60a78822db1c90fc2f17a48
Change-Id: I3775bea45d9028defeb3cfe5856af0366b981241
Change-Id: Ifb9bad040e8a5a9baa4b1dfbfa27823a87bb24c6
Change-Id: Id2f02b7c12632d908d420c05f4acb1ad2ef55166
Copy link
Member

@powerjg powerjg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lots of small style things. One bigger thing that we should sit down and chat about.

/**
* pseudo channel number used for HBM modeling
*/
uint8_t channel_num;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
uint8_t channel_num;
uint8_t channelNum;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

virtual MemPacket* decodePacket(const PacketPtr pkt, Addr pkt_addr,
unsigned int size, bool is_read)
unsigned int size, bool is_read,
uint8_t channel)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Default 0?

MemPacket*
DRAMInterface::decodePacket(const PacketPtr pkt, Addr pkt_addr,
unsigned size, bool is_read)
unsigned size, bool is_read, uint8_t channel)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably should be more verbose and call this the pseudo_channel

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Renamed it to pseudo channel everywhere (to avoid any confusion)

Comment on lines +384 to +386
auto it = rowBurstTicks.begin();
while (it != rowBurstTicks.end()) {
auto current_it = it++;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
auto it = rowBurstTicks.begin();
while (it != rowBurstTicks.end()) {
auto current_it = it++;
for (auto &it : rowBurstTicks) {

Comment on lines +397 to +400
auto it = colBurstTicks.begin();
while (it != colBurstTicks.end())
{
auto current_it = it++;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto above

}

// update the mode
isTimingMode = system()->isTimingMode();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this not handled in SimpleMemCtrl::drainResume?

aakahlow added 4 commits May 11, 2022 23:28
Change-Id: Ifd60610fc40aae32383339688fe4a0be1b517254
Change-Id: I3d4a884074014216268861b023d833b2db8b3bdb
Change-Id: I225e9e135274b3cfa53658b841dbaa9a7c10abd2
Change-Id: I928ebfbd79b184deea3d48b668c7c3ce62b9957e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants