diff options
| author | Wilson Fung <[email protected]> | 2012-07-26 03:22:53 -0800 |
|---|---|---|
| committer | Andrew Boktor <[email protected]> | 2014-08-14 13:48:52 -0700 |
| commit | 9a0e4e4a776a963c9950dc3dcd0d23ee0739b755 (patch) | |
| tree | 70c6f73230fe8fcfdd0fd2a3a7eb525e1f145b80 /src/cuda-sim/ptx-stats.cc | |
| parent | 1c7ed16cc28f1d740ac7abc773eb4016d49fcba4 (diff) | |
Clean up the unordered_map fallback support.
- Now there is only one macro for all use of unordered_map in the code.
- Moving all instances of gcc/cuda version detection into a single file.
- Adding a warning when the fallback is triggered.
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 13542]
Diffstat (limited to 'src/cuda-sim/ptx-stats.cc')
| -rw-r--r-- | src/cuda-sim/ptx-stats.cc | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/cuda-sim/ptx-stats.cc b/src/cuda-sim/ptx-stats.cc index 3578be9..0a9f08d 100644 --- a/src/cuda-sim/ptx-stats.cc +++ b/src/cuda-sim/ptx-stats.cc @@ -80,14 +80,6 @@ public: unsigned line; }; -struct hash_ptx_file_line -{ - std::size_t operator()(const ptx_file_line & pfline) const { - std::hash<unsigned> hash_line; - return hash_line(pfline.line); - } -}; - // holds all statistics collected for a singe PTX source line class ptx_file_line_stats { @@ -113,6 +105,13 @@ public: #if (tr1_hash_map_ismap == 1) typedef tr1_hash_map<ptx_file_line, ptx_file_line_stats> ptx_file_line_stats_map_t; #else +struct hash_ptx_file_line +{ + std::size_t operator()(const ptx_file_line & pfline) const { + std::hash<unsigned> hash_line; + return hash_line(pfline.line); + } +}; typedef tr1_hash_map<ptx_file_line, ptx_file_line_stats, hash_ptx_file_line> ptx_file_line_stats_map_t; #endif |
