23 template <
typename SrcTensorHandleType,
typename DstTensorHandleType>
25 std::vector<std::pair<SrcTensorHandleType*, DstTensorHandleType*>>& tensorHandlePairs)
27 const unsigned int numInputs =
static_cast<unsigned int>(descriptor.m_Inputs.size());
28 tensorHandlePairs.reserve(numInputs);
30 for (
unsigned int i = 0; i < numInputs; ++i)
32 SrcTensorHandleType*
const srcTensorHandle = PolymorphicDowncast<SrcTensorHandleType*>(
33 descriptor.m_Inputs[i]);
34 DstTensorHandleType*
const dstTensorHandle = PolymorphicDowncast<DstTensorHandleType*>(
35 descriptor.m_Outputs[i]);
37 tensorHandlePairs.emplace_back(srcTensorHandle, dstTensorHandle);
55 auto copyFunc = [](
void* dst,
const void* src,
size_t size)
57 memcpy(dst, src, size);
60 for (
const auto& pair : m_TensorHandlePairs)
71 std::vector<TensorHandlePair> tensorHandlePairs;
75 auto copyFunc = [](
void* dst,
const void* src,
size_t size)
77 memcpy(dst, src, size);
80 for (
const auto& pair : tensorHandlePairs)