61,62d60
< if (!(busyBanks[bank].startAccess == curTick() &&
< busyBanks[bank].idx == idx)) {
63a62,81
> }
>
> return true;
> }
>
> void
> BankedArray::reserve(int64 idx)
> {
> if (accessLatency == 0)
> return;
>
> unsigned int bank = mapIndexToBank(idx);
> assert(bank < banks);
>
> if(busyBanks[bank].endAccess >= curTick()) {
> if (busyBanks[bank].startAccess == curTick() &&
> busyBanks[bank].idx == idx) {
> // this is the same reservation (can happen when
> // e.g., reserve the same resource for read and write)
> return; // OK
65,67c83
< // We tried to allocate resources twice
< // in the same cycle for the same addr
< return true;
---
> panic("BankedArray reservation error");
75,76d90
<
< return true;