summaryrefslogtreecommitdiff
path: root/src/cuda-sim/cuda_device_printf.cc
diff options
context:
space:
mode:
authorTor Aamodt <[email protected]>2010-07-18 15:09:01 -0800
committerTor Aamodt <[email protected]>2010-07-18 15:09:01 -0800
commit52d17b482579688b33d265304ef1fdd3ec97d418 (patch)
tree4cf5eba5b79540b88d8bc26570c53fae53718e5b /src/cuda-sim/cuda_device_printf.cc
parent316dfac44cb01925017e495f471c84cce3174937 (diff)
more refactoring of param passing
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 6885]
Diffstat (limited to 'src/cuda-sim/cuda_device_printf.cc')
-rw-r--r--src/cuda-sim/cuda_device_printf.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cuda-sim/cuda_device_printf.cc b/src/cuda-sim/cuda_device_printf.cc
index c2df81b..197a5dd 100644
--- a/src/cuda-sim/cuda_device_printf.cc
+++ b/src/cuda-sim/cuda_device_printf.cc
@@ -103,10 +103,12 @@ void my_cuda_printf(const char *fmtstr,const char *arg_list)
}
}
-void gpgpusim_cuda_vprintf(const ptx_instruction * pI, const ptx_thread_info * thread, const function_info * target_func, unsigned n_return, unsigned n_args )
+void gpgpusim_cuda_vprintf(const ptx_instruction * pI, const ptx_thread_info * thread, const function_info * target_func )
{
char *fmtstr = NULL;
char *arg_list = NULL;
+ unsigned n_return = target_func->has_return();
+ unsigned n_args = target_func->num_args();
assert( n_args == 2 );
for( unsigned arg=0; arg < n_args; arg ++ ) {
const operand_info &actual_param_op = pI->operand_lookup(n_return+1+arg);