aboutsummaryrefslogtreecommitdiff
path: root/src/cuda-sim/ptx_ir.h
diff options
context:
space:
mode:
authorgpgpu-sim <[email protected]>2016-09-05 17:02:04 -0700
committerGitHub <[email protected]>2016-09-05 17:02:04 -0700
commitbab2a234abfadc50cb14dadb01c10595ce6ad1ef (patch)
tree50b0af6609d308635c8c837b3b838b99517cc286 /src/cuda-sim/ptx_ir.h
parentc9852bfe00b508644e894c1ebc34d90081d907c5 (diff)
parent0421e45d3f8796bc9bf1ff3b62c05173f7862463 (diff)
Merge pull request #28 from jwang323/cdp_clean
Initial support of CUDA Dynamic Parallelism on GPGPUSim
Diffstat (limited to 'src/cuda-sim/ptx_ir.h')
-rw-r--r--src/cuda-sim/ptx_ir.h17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/cuda-sim/ptx_ir.h b/src/cuda-sim/ptx_ir.h
index 601a13d..55b01fd 100644
--- a/src/cuda-sim/ptx_ir.h
+++ b/src/cuda-sim/ptx_ir.h
@@ -291,6 +291,7 @@ private:
std::list<operand_info> m_initializer;
static unsigned sm_next_uid;
+
};
class symbol_table {
@@ -330,6 +331,11 @@ public:
iterator const_iterator_end() { return m_consts.end();}
void dump();
+
+ //Jin: handle instruction group for cdp
+ symbol_table* start_inst_group();
+ symbol_table* end_inst_group();
+
private:
unsigned m_reg_allocator;
unsigned m_shared_next;
@@ -347,6 +353,10 @@ private:
std::list<symbol*> m_consts;
std::map<std::string,function_info*> m_function_info_lookup;
std::map<std::string,symbol_table*> m_function_symtab_lookup;
+
+ //Jin: handle instruction group for cdp
+ unsigned m_inst_group_id;
+ std::map<std::string,symbol_table*> m_inst_group_symtab;
};
class operand_info {
@@ -690,7 +700,7 @@ public:
}
bool is_immediate_address() const {
- return m_immediate_address;
+ return m_immediate_address;
}
bool is_literal() const { return m_type == int_t ||
@@ -1200,6 +1210,8 @@ public:
{
return m_args.size();
}
+ unsigned get_args_aligned_size();
+
const symbol* get_arg( unsigned n ) const
{
assert( n < m_args.size() );
@@ -1288,6 +1300,9 @@ private:
static std::vector<ptx_instruction*> s_g_pc_to_insn; // a direct mapping from PC to instruction
static unsigned sm_next_uid;
+
+ //parameter size for device kernels
+ int m_args_aligned_size;
};
class arg_buffer_t {