diff options
| author | Tayler Hetherington <[email protected]> | 2012-09-28 12:11:35 -0800 |
|---|---|---|
| committer | Andrew Boktor <[email protected]> | 2014-08-14 13:49:21 -0700 |
| commit | 6f8637f120670157230074d3b3f847f00d3e3e2c (patch) | |
| tree | 2198f7759ec496cea719f04786ecf8002a6c0567 | |
| parent | 495cfab5e38d80c8daddf170dce84f3e2d08f537 (diff) | |
Updating comment in l1/l2 access functions
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 14199]
| -rw-r--r-- | src/gpgpu-sim/gpu-cache.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gpgpu-sim/gpu-cache.cc b/src/gpgpu-sim/gpu-cache.cc index 634ad61..63b5fc9 100644 --- a/src/gpgpu-sim/gpu-cache.cc +++ b/src/gpgpu-sim/gpu-cache.cc @@ -561,7 +561,8 @@ enum cache_request_status l1_cache::access( new_addr_type addr, mem_fetch *mf, u enum cache_request_status status = m_tag_array.probe(block_addr,cache_index); - // Each function pointer (m_rd/wr_hit/miss) is set in the data_cache constructor to reflect the corresponding cache configuration options + // Each function pointer ( m_[rd/wr]_[hit/miss] ) is set in the data_cache constructor to reflect the corresponding cache configuration options. + // Function pointers were used to avoid many long conditional branches resulting from many cache configuration options. if(wr){ // Write if(status == HIT){ return (this->*m_wr_hit)(addr, cache_index, mf, time, events); @@ -587,7 +588,8 @@ enum cache_request_status l2_cache::access( new_addr_type addr, mem_fetch *mf, u unsigned cache_index = (unsigned)-1; enum cache_request_status status = m_tag_array.probe(block_addr,cache_index); - // Each function pointer (m_rd/wr_hit/miss) is set in the data_cache constructor to reflect the corresponding cache configuration options + // Each function pointer ( m_[rd/wr]_[hit/miss] ) is set in the data_cache constructor to reflect the corresponding cache configuration options. + // Function pointers were used to avoid many long conditional branches resulting from many cache configuration options. if(wr){ // Write if(status == HIT){ return (this->*m_wr_hit)(addr, cache_index, mf, time, events); |
