diff options
| author | Inderpreet Singh <[email protected]> | 2012-07-18 23:17:29 -0800 |
|---|---|---|
| committer | Andrew Boktor <[email protected]> | 2014-08-14 13:47:33 -0700 |
| commit | 8d59181b80697dfc717abcd55da9c899e4cf0d07 (patch) | |
| tree | e34982e972f5cea3585a902e06bc38a006b042f0 /src/cuda-sim/ptx_ir.cc | |
| parent | 896e5c9a34e1b1230a67fb714d8290cd6f7f979b (diff) | |
Copied in Arun's SIMT stack fix for recursive calls (CL8574)
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 13410]
Diffstat (limited to 'src/cuda-sim/ptx_ir.cc')
| -rw-r--r-- | src/cuda-sim/ptx_ir.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/cuda-sim/ptx_ir.cc b/src/cuda-sim/ptx_ir.cc index 102ae40..61b45e3 100644 --- a/src/cuda-sim/ptx_ir.cc +++ b/src/cuda-sim/ptx_ir.cc @@ -1162,6 +1162,19 @@ ptx_instruction::ptx_instruction( int opcode, m_source_file = file?file:"<unknown>"; m_source_line = line; m_source = source; + + if (opcode == CALL_OP) { + const operand_info &target = func_addr(); + assert( target.is_function_address() ); + const symbol *func_addr = target.get_symbol(); + const function_info *target_func = func_addr->get_pc(); + std::string fname = target_func->get_name(); + + if (fname =="vprintf"){ + m_is_printf = true; + } + + } } void ptx_instruction::print_insn() const |
