minor update

This commit is contained in:
Blaise Tine
2020-11-23 12:21:39 -08:00
parent a7cd991c87
commit 664ce28426
3 changed files with 3 additions and 24 deletions

View File

@@ -301,19 +301,9 @@ void opae_sim::avs_bus() {
if (vortex_afu_->avs_read) {
assert(0 == vortex_afu_->mem_bank_select);
dram_rd_req_t dram_req;
dram_req.addr = vortex_afu_->avs_address;
ram_.read(vortex_afu_->avs_address * CACHE_BLOCK_SIZE, CACHE_BLOCK_SIZE, dram_req.block.data());
dram_req.cycles_left = DRAM_LATENCY;
for (auto& req : dram_reads_) {
if (req.addr == dram_req.addr) {
dram_req.cycles_left = req.cycles_left;
break;
}
}
dram_req.cycles_left = DRAM_LATENCY;
dram_reads_.emplace_back(dram_req);
/*printf("%0ld: [sim] DRAM Rd Req: addr=%x, pending={", timestamp, dram_req.addr * CACHE_BLOCK_SIZE);
for (auto& req : dram_reads_) {

View File

@@ -179,20 +179,10 @@ void Simulator::eval_dram_bus() {
}
}
} else {
dram_req_t dram_req;
dram_req.tag = vortex_->dram_req_tag;
dram_req.addr = vortex_->dram_req_addr;
dram_req_t dram_req;
dram_req.tag = vortex_->dram_req_tag;
ram_->read(vortex_->dram_req_addr * GLOBAL_BLOCK_SIZE, GLOBAL_BLOCK_SIZE, dram_req.block.data());
dram_req.cycles_left = DRAM_LATENCY;
for (auto& req : dram_rsp_vec_) {
if (req.addr == dram_req.addr) {
dram_req.cycles_left = req.cycles_left;
break;
}
}
dram_rsp_vec_.emplace_back(dram_req);
}
}

View File

@@ -52,7 +52,6 @@ private:
int cycles_left;
std::array<uint8_t, GLOBAL_BLOCK_SIZE> block;
uint32_t tag;
uint32_t addr;
} dram_req_t;
std::unordered_map<int, std::stringstream> print_bufs_;