summaryrefslogtreecommitdiff
path: root/src/cuda-sim/ptx_ir.h
diff options
context:
space:
mode:
authorTor Aamodt <[email protected]>2010-07-17 00:06:40 -0800
committerTor Aamodt <[email protected]>2010-07-17 00:06:40 -0800
commitb6661da800739b0fca9e01ba6d5afaca4f286d84 (patch)
tree1ae2883b6a75476bae851abf2fac20619a2afb5c /src/cuda-sim/ptx_ir.h
parentd67e0e6d7c50a5c6f567e387e17782f022553264 (diff)
- bug fix: parsing hex int constants didn't have a-fA-F!?!
- modify template to use printf from kernel (this works on our Fermi card--want it working on simulator for debugging) - add support for extern function declarations (so don't try to assemble them)... printf is extern [git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 6862]
Diffstat (limited to 'src/cuda-sim/ptx_ir.h')
-rw-r--r--src/cuda-sim/ptx_ir.h17
1 files changed, 5 insertions, 12 deletions
diff --git a/src/cuda-sim/ptx_ir.h b/src/cuda-sim/ptx_ir.h
index aca3556..67b274c 100644
--- a/src/cuda-sim/ptx_ir.h
+++ b/src/cuda-sim/ptx_ir.h
@@ -879,18 +879,8 @@ private:
class function_info {
public:
- function_info(int entry_point )
- {
- m_entry_point = entry_point?true:false;
- num_reconvergence_pairs = 0;
- m_symtab = NULL;
- m_assembled = false;
- m_return_var_sym = NULL;
- m_kernel_info.cmem = 0;
- m_kernel_info.lmem = 0;
- m_kernel_info.regs = 0;
- m_kernel_info.smem = 0;
- }
+ function_info(int entry_point );
+ bool is_extern() const { return m_extern; }
void set_name(const char *name)
{
m_name = name;
@@ -1079,7 +1069,9 @@ public:
}
private:
+ unsigned m_uid;
bool m_entry_point;
+ bool m_extern;
bool m_assembled;
std::string m_name;
ptx_instruction **m_instr_mem;
@@ -1101,6 +1093,7 @@ private:
symbol_table *m_symtab;
static std::vector<ptx_instruction*> s_g_pc_to_insn; // a direct mapping from PC to instruction
+ static unsigned sm_next_uid;
};
/*******************************/