diff options
| author | Tor Aamodt <[email protected]> | 2010-10-03 21:23:24 -0800 |
|---|---|---|
| committer | Tor Aamodt <[email protected]> | 2010-10-03 21:23:24 -0800 |
| commit | d859e08188eb5863888a9b018cf4aec6d0419c40 (patch) | |
| tree | 6ab5338ae1b7d99828285bc7b0387d627f01b554 | |
| parent | cd88d9b8dad58a40f0d5680e8386190472e607a3 (diff) | |
bug fix for last check in (problem w/ CUDA 3.1 regressions)
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 7812]
| -rw-r--r-- | src/cuda-sim/cuda-sim.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/cuda-sim/cuda-sim.cc b/src/cuda-sim/cuda-sim.cc index 80aa60b..c28f1a0 100644 --- a/src/cuda-sim/cuda-sim.cc +++ b/src/cuda-sim/cuda-sim.cc @@ -904,9 +904,10 @@ unsigned datatype2size( unsigned data_type ) void init_inst_classification_stat() { - static bool init=false; - if( init ) return; - init=true; + static std::set<unsigned> init; + if( init.find(g_ptx_kernel_count) != init.end() ) + return; + init.insert(g_ptx_kernel_count); char kernelname[256] =""; #define MAX_CLASS_KER 1024 if (!g_inst_classification_stat) g_inst_classification_stat = (void**)calloc(MAX_CLASS_KER, sizeof(void*)); |
