| 265 | } |
| 266 | |
| 267 | void do_copy_diff_q32_q32(const TensorND& dst, const TensorND& src) { |
| 268 | auto isrc = |
| 269 | tensor_iter_valonly<DTypeTrait<dtype::QuantizedS32>::ctype>(src).begin(); |
| 270 | auto idst = |
| 271 | tensor_iter_valonly<DTypeTrait<dtype::QuantizedS32>::ctype>(dst).begin(); |
| 272 | auto src_dt_parm = src.layout.dtype.param<dtype::QuantizedS32>(); |
| 273 | auto dst_dt_parm = dst.layout.dtype.param<dtype::QuantizedS32>(); |
| 274 | for (size_t i = 0, it = dst.layout.total_nr_elems(); i < it; ++i) { |
| 275 | *idst = dst_dt_parm.quantize(src_dt_parm.dequantize(*isrc)); |
| 276 | ++idst; |
| 277 | ++isrc; |
| 278 | } |
| 279 | } |
| 280 | |
| 281 | void do_copy_diff_u8_q8(const TensorND& dst, const TensorND& src) { |
| 282 | auto isrc = tensor_iter_valonly<DTypeTrait<dtype::Uint8>::ctype>(src).begin(); |
no test coverage detected