summaryrefslogtreecommitdiff
path: root/src/gpgpu-sim/shader.cc
diff options
context:
space:
mode:
authorMengchi Zhang <[email protected]>2019-07-08 12:37:52 -0400
committerMengchi Zhang <[email protected]>2019-07-08 12:37:52 -0400
commitb3e786e3d8d720217f36a214e9b5be9a19ab9dd2 (patch)
tree4606248aae16685a12a1e4943cdb06d2ca9580ed /src/gpgpu-sim/shader.cc
parent7e9591a24ffbe645cfaa7a84b33a82edb9fca0bc (diff)
Move opcode_latency_int thus pass gpgpu_context into many classes
Signed-off-by: Mengchi Zhang <[email protected]>
Diffstat (limited to 'src/gpgpu-sim/shader.cc')
-rw-r--r--src/gpgpu-sim/shader.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gpgpu-sim/shader.cc b/src/gpgpu-sim/shader.cc
index 69b619a..4d12068 100644
--- a/src/gpgpu-sim/shader.cc
+++ b/src/gpgpu-sim/shader.cc
@@ -46,6 +46,7 @@
#include <limits.h>
#include "traffic_breakdown.h"
#include "shader_trace.h"
+#include "../../libcuda/gpgpu_context.h"
#define PRIORITIZE_MSHR_OVER_WB 1
#define MAX(a,b) (((a)>(b))?(a):(b))
@@ -69,7 +70,7 @@ shader_core_ctx::shader_core_ctx( class gpgpu_sim *gpu,
class simt_core_cluster *cluster,
unsigned shader_id,
unsigned tpc_id,
- const struct shader_core_config *config,
+ const shader_core_config *config,
const struct memory_config *mem_config,
shader_core_stats *stats )
: core_t( gpu, NULL, config->warp_size, config->n_thread_per_shader ),
@@ -3018,7 +3019,7 @@ void shader_core_config::set_pipeline_latency() {
* [3] MAD
* [4] DIV
*/
- sscanf(opcode_latency_int, "%u,%u,%u,%u,%u",
+ sscanf(gpgpu_ctx->func_sim->opcode_latency_int, "%u,%u,%u,%u,%u",
&int_latency[0],&int_latency[1],&int_latency[2],
&int_latency[3],&int_latency[4]);
sscanf(opcode_latency_fp, "%u,%u,%u,%u,%u",
@@ -3786,7 +3787,7 @@ void opndcoll_rfu_t::collector_unit_t::dispatch()
simt_core_cluster::simt_core_cluster( class gpgpu_sim *gpu,
unsigned cluster_id,
- const struct shader_core_config *config,
+ const shader_core_config *config,
const struct memory_config *mem_config,
shader_core_stats *stats,
class memory_stats_t *mstats )