diff options
author | Tony Gutierrez <anthony.gutierrez@amd.com> | 2016-10-26 22:47:47 -0400 |
---|---|---|
committer | Tony Gutierrez <anthony.gutierrez@amd.com> | 2016-10-26 22:47:47 -0400 |
commit | aa7364276f16bbe6aa300b43bc57ff1b73be42a7 (patch) | |
tree | bd384607585d98dd996b88c74864aa105b6843a7 /src/gpu-compute/shader.cc | |
parent | 844fb845a51b15f13c7c744e0d5fdf5567c3da98 (diff) | |
download | gem5-aa7364276f16bbe6aa300b43bc57ff1b73be42a7.tar.xz |
gpu-compute: use System cache line size in the GPU
Diffstat (limited to 'src/gpu-compute/shader.cc')
-rw-r--r-- | src/gpu-compute/shader.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gpu-compute/shader.cc b/src/gpu-compute/shader.cc index d02f95d29..e47edce2c 100644 --- a/src/gpu-compute/shader.cc +++ b/src/gpu-compute/shader.cc @@ -224,7 +224,7 @@ void Shader::doFunctionalAccess(RequestPtr req, MemCmd cmd, void *data, bool suppress_func_errors, int cu_id) { - unsigned block_size = RubySystem::getBlockSizeBytes(); + int block_size = cuList.at(cu_id)->cacheLineSize(); unsigned size = req->getSize(); Addr tmp_addr; @@ -342,7 +342,7 @@ Shader::AccessMem(uint64_t address, void *ptr, uint32_t size, int cu_id, { uint8_t *data_buf = (uint8_t*)ptr; - for (ChunkGenerator gen(address, size, RubySystem::getBlockSizeBytes()); + for (ChunkGenerator gen(address, size, cuList.at(cu_id)->cacheLineSize()); !gen.done(); gen.next()) { Request *req = new Request(0, gen.addr(), gen.size(), 0, cuList[0]->masterId(), 0, 0, 0); |