MCPcopy Create free account
hub / github.com/apache/impala / TryDeepCopy

Method TryDeepCopy

be/src/runtime/tuple-ir.cc:59–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57}
58
59bool Tuple::TryDeepCopy(uint8_t** dst_start, const uint8_t* dst_end, int* offset_start,
60 const TupleDescriptor& desc, bool convert_ptrs) const {
61 uint8_t* dst = *dst_start;
62 int offset = *offset_start;
63 if (!TryMemCopy(dst, dst_end, desc.byte_size(), this)) return false;
64 Tuple* dst_tuple = reinterpret_cast<Tuple*>(dst);
65 dst += desc.byte_size();
66 offset += desc.byte_size();
67 if (!dst_tuple->TryDeepCopyStrings(&dst, dst_end, &offset, desc, convert_ptrs)) {
68 return false;
69 }
70 if (!dst_tuple->TryDeepCopyCollections(&dst, dst_end, &offset, desc, convert_ptrs)) {
71 return false;
72 }
73 *dst_start = dst;
74 *offset_start = offset;
75 return true;
76}
77
78bool Tuple::TryDeepCopyStrings(uint8_t** data, const uint8_t* data_end, int* offset,
79 const TupleDescriptor& desc, bool convert_ptrs) {

Callers 1

TryAppendTupleMethod · 0.80

Calls 4

TryMemCopyFunction · 0.85
TryDeepCopyStringsMethod · 0.80
byte_sizeMethod · 0.45

Tested by

no test coverage detected