Lines Matching +full:- +full:15 +full:v
8 * http://www.apache.org/licenses/LICENSE-2.0
26 uint8_t v = 4; in TEST() local
27 p.pack(v); in TEST()
29 ASSERT_EQ(p.size(), sizeof(v)); in TEST()
38 uint16_t v = 0x8604; in TEST() local
39 p.pack(v); in TEST()
41 ASSERT_EQ(p.size(), sizeof(v)); in TEST()
50 uint32_t v = 0x02008604; in TEST() local
51 p.pack(v); in TEST()
53 ASSERT_EQ(p.size(), sizeof(v)); in TEST()
62 uint64_t v = 0x1122334402008604ull; in TEST() local
63 p.pack(v); in TEST()
65 ASSERT_EQ(p.size(), sizeof(v)); in TEST()
74 uint24_t v = 0x112358; in TEST() local
75 p.pack(v); in TEST()
77 ASSERT_EQ(p.size(), types::nrFixedBits<decltype(v)> / CHAR_BIT); in TEST()
85 // individual bytes are packed low-order-bits first in TEST()
102 // individual bytes are packed low-order-bits first in TEST()
117 // individual bytes are packed low-order-bits first in TEST()
120 std::bitset<8> v(0xc9); in TEST() local
121 p.pack(v); in TEST()
123 ASSERT_EQ(p.size(), v.size() / CHAR_BIT); in TEST()
131 // individual bytes are packed low-order-bits first in TEST()
146 // individual bytes are packed low-order-bits first in TEST()
148 // v1[7:0] v1[15:9] v1[23:16] v1[31:24] in TEST()
150 std::bitset<32> v(0x02008604); in TEST() local
151 p.pack(v); in TEST()
153 ASSERT_EQ(p.size(), v.size() / CHAR_BIT); in TEST()
163 auto v = std::make_tuple(static_cast<uint16_t>(0x8604), 'A'); in TEST() local
164 p.pack(v); in TEST()
174 // an array of bytes will be output verbatim, low-order element first in TEST()
176 std::array<uint8_t, 4> v = {{0x02, 0x00, 0x86, 0x04}}; in TEST() local
177 p.pack(v); in TEST()
179 ASSERT_EQ(p.size(), v.size() * sizeof(v[0])); in TEST()
187 // an array of multi-byte values will be output in order low-order in TEST()
188 // element first, each multi-byte element in LSByte order in TEST()
189 // v[0][7:0] v[0][15:9] v[0][23:16] v[0][31:24] in TEST()
190 // v[1][7:0] v[1][15:9] v[1][23:16] v[1][31:24] in TEST()
191 // v[2][7:0] v[2][15:9] v[2][23:16] v[2][31:24] in TEST()
192 // v[3][7:0] v[3][15:9] v[3][23:16] v[3][31:24] in TEST()
194 std::array<uint32_t, 4> v = { in TEST() local
196 p.pack(v); in TEST()
198 ASSERT_EQ(p.size(), v.size() * sizeof(v[0])); in TEST()
207 // a vector of multi-byte values will be output in order low-order in TEST()
208 // element first, each multi-byte element in LSByte order in TEST()
209 // v[0][7:0] v[0][15:9] v[0][23:16] v[0][31:24] in TEST()
210 // v[1][7:0] v[1][15:9] v[1][23:16] v[1][31:24] in TEST()
211 // v[2][7:0] v[2][15:9] v[2][23:16] v[2][31:24] in TEST()
212 // v[3][7:0] v[3][15:9] v[3][23:16] v[3][31:24] in TEST()
214 std::vector<uint32_t> v = { in TEST() local
216 p.pack(v); in TEST()
218 ASSERT_EQ(p.size(), v.size() * sizeof(v[0])); in TEST()
227 // a vector of bytes will be output verbatim, low-order element first in TEST()
229 std::vector<uint8_t> v = {0x02, 0x00, 0x86, 0x04}; in TEST() local
230 p.pack(v); in TEST()
232 ASSERT_EQ(p.size(), v.size() * sizeof(v[0])); in TEST()
263 std::optional<uint32_t> v; in TEST() local
264 p.pack(v); in TEST()
276 std::optional<uint32_t> v(0x04860002); in TEST() local
277 p.pack(v); in TEST()
337 // all elements will be processed in order, with each multi-byte in TEST()
339 // v1[7:0] v2[7:0] v2[15:8] v3[7:0] v3[15:8] v3[23:16] v3[31:24] in TEST()
340 // v4[7:0] v4[15:8] v4[23:16] v4[31:24] in TEST()
358 // all elements will be processed in order, with each multi-byte in TEST()
360 // v1[7:0] v2[7:0] v2[15:8] v3[7:0] v3[15:8] v3[23:16] v3[31:24] in TEST()
361 // v4[7:0] v4[15:8] v4[23:16] v4[31:24] in TEST()
368 auto v = std::make_tuple(v1, v2, v3, v4); in TEST() local
369 p.pack(v); in TEST()
395 // each element will be added, filling the low-order bits first in TEST()
396 // with multi-byte values getting added LSByte first in TEST()
408 // concat binary: 0b1101101110011110 -> 0xdb9e -> 0x9e 0xdb (LSByte first) in TEST()
419 // unaligned multi-byte values will be packed the same as in TEST()
420 // other bits, effectively building up a large value, low-order in TEST()
426 // v4[15:13] will occupy k[3][2:0] in TEST()
442 // -> 0x9dbc3bd3cd2ad296 -> 0x96 0xd2 0x2a 0xcd 0xd3 0x3b 0xbc 0x9d in TEST()
454 // inspired from a real-world case of Get Session Info in TEST()
456 constexpr uint8_t maxSessions = 15; // number of possible active sessions in TEST()