summaryrefslogtreecommitdiff
path: root/src/cuda-sim/instructions.cc
diff options
context:
space:
mode:
authorTor Aamodt <[email protected]>2010-07-16 12:47:47 -0800
committerTor Aamodt <[email protected]>2010-07-16 12:47:47 -0800
commit748a2d560b0032049e12ec57e8000941ff3e589a (patch)
treef0c5e7d13321bdf76577255fb322b6586e87a7f5 /src/cuda-sim/instructions.cc
parent93a64be21eb3746de0b96a2f2a365f59cd8f1bbc (diff)
- BlackScholes passing on CUDA 3.1
- Added fma operation by simply calling mad, however in reality fma is supposed to be more accurate than mad. For now, properly emulating fma (to get the extra precision) isn't a priority. [git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 6839]
Diffstat (limited to 'src/cuda-sim/instructions.cc')
-rw-r--r--src/cuda-sim/instructions.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/cuda-sim/instructions.cc b/src/cuda-sim/instructions.cc
index 4479cbe..226e965 100644
--- a/src/cuda-sim/instructions.cc
+++ b/src/cuda-sim/instructions.cc
@@ -1386,6 +1386,13 @@ void exit_impl( const ptx_instruction *pI, ptx_thread_info *thread )
thread->set_done();
}
+void mad_def( const ptx_instruction *pI, ptx_thread_info *thread );
+
+void fma_impl( const ptx_instruction *pI, ptx_thread_info *thread )
+{
+ mad_def(pI,thread);
+}
+
void ld_impl( const ptx_instruction *pI, ptx_thread_info *thread )
{
const operand_info &dst = pI->dst();
@@ -1502,6 +1509,11 @@ void mad24_impl( const ptx_instruction *pI, ptx_thread_info *thread )
}
void mad_impl( const ptx_instruction *pI, ptx_thread_info *thread )
+{
+ mad_def(pI,thread);
+}
+
+void mad_def( const ptx_instruction *pI, ptx_thread_info *thread )
{
const operand_info &dst = pI->dst();
const operand_info &src1 = pI->src1();