summaryrefslogtreecommitdiff
path: root/src/gpgpu-sim/gpu-sim.h
diff options
context:
space:
mode:
authorTim Rogers <[email protected]>2017-05-09 13:39:46 -0400
committerGitHub <[email protected]>2017-05-09 13:39:46 -0400
commitbcd1867f8f800f2f4eda9da4e8b2b2d6a567e622 (patch)
tree81d2baa94e8f8f298aff5b44e164df43ae30a57d /src/gpgpu-sim/gpu-sim.h
parent54529f8b3556427526fd416118c444ce0eb10a21 (diff)
parent96d528311239d6ff82d7bec807a2509b344c9a60 (diff)
Merge branch 'dev' into dev
Diffstat (limited to 'src/gpgpu-sim/gpu-sim.h')
-rw-r--r--src/gpgpu-sim/gpu-sim.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/gpgpu-sim/gpu-sim.h b/src/gpgpu-sim/gpu-sim.h
index 33fffd3..a2d1b9b 100644
--- a/src/gpgpu-sim/gpu-sim.h
+++ b/src/gpgpu-sim/gpu-sim.h
@@ -492,6 +492,7 @@ private:
std::string executed_kernel_info_string(); //< format the kernel information into a string for stat printout
void clear_executed_kernel_info(); //< clear the kernel information after stat printout
+
public:
unsigned long long gpu_sim_insn;
unsigned long long gpu_tot_sim_insn;
@@ -504,6 +505,25 @@ public:
void change_cache_config(FuncCache cache_config);
void set_cache_config(std::string kernel_name);
+ //Jin: functional simulation for CDP
+private:
+ //set by stream operation every time a functoinal simulation is done
+ bool m_functional_sim;
+ kernel_info_t * m_functional_sim_kernel;
+
+public:
+ bool is_functional_sim() { return m_functional_sim; }
+ kernel_info_t * get_functional_kernel() { return m_functional_sim_kernel; }
+ void functional_launch(kernel_info_t * k) {
+ m_functional_sim = true;
+ m_functional_sim_kernel = k;
+ }
+ void finish_functional_sim(kernel_info_t * k) {
+ assert(m_functional_sim);
+ assert(m_functional_sim_kernel == k);
+ m_functional_sim = false;
+ m_functional_sim_kernel = NULL;
+ }
};
#endif