MCPcopy Create free account
hub / github.com/4paradigm/OpenMLDB / GetDstStrSize

Function GetDstStrSize

src/codec/memcomparable_format.h:50–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

48static constexpr int RDB_ESCAPE_LENGTH = 9;
49
50static inline int32_t GetDstStrSize(int32_t size) {
51 if (size == 0) {
52 return RDB_ESCAPE_LENGTH;
53 }
54 int32_t byte_num = (((size) >> 3) + !!((size)&0x07));
55 return byte_num * RDB_ESCAPE_LENGTH;
56}
57
58static inline void SwapFloatBytes(uchar *const dst, const uchar *const src) {
59 dst[0] = src[3];

Callers 1

TEST_FFunction · 0.85

Calls

no outgoing calls

Tested by 1

TEST_FFunction · 0.68