diff options
| author | aamir <[email protected]> | 2018-08-10 11:35:10 -0700 |
|---|---|---|
| committer | aamir <[email protected]> | 2018-08-10 11:35:10 -0700 |
| commit | d22c3dcf433dc56c07be087f78143c0eb06dff5f (patch) | |
| tree | f6d0bbc0e35b7fdb00ec13a73f1b2c59e5b49da5 /src/cuda-sim | |
| parent | 12a8816c32a134693011d8b9e587f109e4d7e7f9 (diff) | |
corrected a bug in bfi implementation
Diffstat (limited to 'src/cuda-sim')
| -rw-r--r-- | src/cuda-sim/instructions.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cuda-sim/instructions.cc b/src/cuda-sim/instructions.cc index d0396a5..0f7b0ef 100644 --- a/src/cuda-sim/instructions.cc +++ b/src/cuda-sim/instructions.cc @@ -1599,7 +1599,7 @@ void bfi_impl( const ptx_instruction *pI, ptx_thread_info *thread ) { unsigned len = src4_data.u32 & 0xFF; for(i=0;i<len && pos+i<max;i++){ data.u32=(~((0x00000001)<<(pos+i)))&data.u32; - data.u32=data.u32|(src1_data.u32&((0x00000001)<<(pos+i))); + data.u32=data.u32|((src1_data.u32&((0x00000001)<<(i)))<<(pos)); } thread->set_operand_value(dst, data, i_type, thread, pI); } |
