diff options
| author | Jonathan <[email protected]> | 2018-05-24 15:35:05 -0700 |
|---|---|---|
| committer | Jonathan <[email protected]> | 2018-05-24 15:35:05 -0700 |
| commit | 64e80dd0c771dce517973ec0a27eb01238f4d8e6 (patch) | |
| tree | 24c84d3f1e6d326182ef81b99f5003031ba8d3a8 | |
| parent | 9636bbfef261c732c990b7159c9ad699888f5553 (diff) | |
changed assertion to warning when binding to previously bound name.
| -rw-r--r-- | src/cuda-sim/cuda-sim.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cuda-sim/cuda-sim.cc b/src/cuda-sim/cuda-sim.cc index 2a197c3..34368ce 100644 --- a/src/cuda-sim/cuda-sim.cc +++ b/src/cuda-sim/cuda-sim.cc @@ -157,7 +157,9 @@ void gpgpu_t::gpgpu_ptx_sim_bindTextureToArray(const struct textureReference* te std::map<std::string,const struct cudaArray*>::const_iterator t=m_NameToCudaArray.find(texname); //check that there's nothing there first - assert(t == m_NameToCudaArray.end()); + if(t != m_NameToCudaArray.end()){ + printf("GPGPU-Sim PTX: Warning: binding to texref associated with %s, which was previously bound.\nImplicitly unbinding texref associated to %s first\n", texname.c_str(), texname.c_str()); + } m_NameToCudaArray[texname] = array; unsigned int texel_size_bits = array->desc.w + array->desc.x + array->desc.y + array->desc.z; unsigned int texel_size = texel_size_bits/8; |
