Home
last modified time | relevance | path

Searched refs:buffer (Results 1 - 25 of 1641) sorted by relevance

12345678910>>...66

/arkcompiler/runtime_core/libpandabase/tests/
H A Dring_buffer_test.cpp25 constexpr RingBuffer<int, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
27 ASSERT_EQ(buffer.size(), 0U); in TEST()
28 ASSERT_EQ(buffer.capacity(), DEFAULT_BUFFER_SIZE); in TEST()
29 ASSERT_EQ(buffer.begin(), buffer.end()); in TEST()
30 ASSERT_EQ(buffer.cbegin(), buffer.cend()); in TEST()
31 ASSERT_TRUE(buffer.empty()); in TEST()
32 ASSERT_EQ(buffer.capacity(), DEFAULT_BUFFER_SIZE); in TEST()
33 ASSERT_FALSE(buffer in TEST()
38 RingBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
90 RingBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
[all...]
/arkcompiler/runtime_core/static_core/libpandabase/tests/
H A Dring_buffer_test.cpp38 RingBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
41 buffer.push_back(i); in TEST()
42 ASSERT_EQ(buffer.size(), i + 1U); in TEST()
43 ASSERT_EQ(buffer.front(), 0U); in TEST()
44 ASSERT_EQ(buffer.back(), i); in TEST()
47 ASSERT_EQ(buffer.size(), DEFAULT_BUFFER_SIZE); in TEST()
48 ASSERT_NE(buffer.begin(), buffer.end()); in TEST()
49 ASSERT_FALSE(buffer.empty()); in TEST()
50 ASSERT_TRUE(buffer in TEST()
90 RingBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
[all...]
/arkcompiler/runtime_core/static_core/libpandabase/utils/
H A Dsmall_vector.h58 * SmallVector stores `N` elements statically inside its static buffer. Static buffer shares memory with a std::vector
59 * that will be created once number of elements exceed size of the static buffer - `N`.
214 buffer.size = 0; in SmallVector()
222 buffer.size = 0; in SmallVector()
235 buffer.size = 0; in SmallVector()
242 buffer.size = other.buffer.size; in SmallVector()
244 for (uint32_t i = 0; i < buffer.size; ++i) { in SmallVector()
246 new (&buffer in SmallVector()
670 StaticBuffer buffer; global() member
[all...]
/test/xts/acts/commonlibrary/thirdparty/musl/entry/src/main/cpp/
H A Dcomplexndk.cpp89 char buffer[20]; in Conj() local
91 sprintf(buffer, "%.2f", getRealAndImage); in Conj()
92 strcat(backParam, buffer); in Conj()
95 sprintf(buffer, "%.2f", getRealAndImage); in Conj()
96 strcat(backParam, buffer); in Conj()
117 char buffer[20]; in ConjF() local
119 sprintf(buffer, "%.2f", getRealAndImage); in ConjF()
120 strcat(backParam, buffer); in ConjF()
123 sprintf(buffer, "%.2f", getRealAndImage); in ConjF()
124 strcat(backParam, buffer); in ConjF()
142 char buffer[20]; ConjL() local
169 char buffer[20]; CPow() local
198 char buffer[20]; CPowF() local
225 char buffer[20]; CPowL() local
250 char buffer[20]; CProj() local
278 char buffer[20]; CProjF() local
303 char buffer[20]; CProjL() local
328 char buffer[20]; CSin() local
353 char buffer[20]; CSinF() local
378 char buffer[20]; CSinL() local
403 char buffer[20]; CSinH() local
428 char buffer[20]; CSinHf() local
453 char buffer[20]; CSinHl() local
478 char buffer[20]; CSqrt() local
503 char buffer[20]; CSqrtF() local
528 char buffer[20]; CSqrtL() local
553 char buffer[20]; CTan() local
578 char buffer[20]; CTanF() local
603 char buffer[20]; CTanL() local
628 char buffer[20]; CTanH() local
653 char buffer[20]; CTanHf() local
678 char buffer[20]; CTanHl() local
749 char buffer[20]; Cacos() local
775 char buffer[20]; Cacosl() local
801 char buffer[20]; Cacosf() local
827 char buffer[20]; Cacosh() local
853 char buffer[20]; Cacoshf() local
879 char buffer[20]; Cacoshl() local
962 char buffer[20]; Casin() local
988 char buffer[20]; Casinl() local
1014 char buffer[20]; Casinf() local
1040 char buffer[20]; Casinh() local
1066 char buffer[20]; Casinhf() local
1092 char buffer[20]; Casinhl() local
1118 char buffer[20]; Catan() local
1144 char buffer[20]; Catanl() local
1170 char buffer[20]; Catanf() local
1196 char buffer[20]; Catanh() local
1222 char buffer[20]; Catanhf() local
1248 char buffer[20]; Catanhl() local
1274 char buffer[20]; Ccos() local
1300 char buffer[20]; Ccosl() local
1326 char buffer[20]; Ccosf() local
1352 char buffer[20]; Ccosh() local
1378 char buffer[20]; Ccoshf() local
1404 char buffer[20]; Ccoshl() local
1430 char buffer[20]; Cexp() local
1456 char buffer[20]; Cexpl() local
1482 char buffer[20]; Cexpf() local
1508 char buffer[20]; Clog() local
1534 char buffer[20]; Clogf() local
1560 char buffer[20]; Clogl() local
[all...]
/test/xts/hats/kernel/dmabuffer/
H A Ddmabuf_alloc.cpp85 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; in HWTEST_F() local
86 ASSERT_EQ(0, DmabufHeapBufferAlloc(heapFd, &buffer)); in HWTEST_F()
88 void *ptr = mmap(nullptr, BUFFER_SIZE, PROT_READ | PROT_WRITE, MAP_SHARED, buffer.fd, 0); in HWTEST_F()
91 ASSERT_EQ(0, DmabufHeapBufferSyncStart(buffer.fd, DMA_BUF_HEAP_BUF_SYNC_RW)); in HWTEST_F()
95 ASSERT_EQ(0, DmabufHeapBufferSyncEnd(buffer.fd, DMA_BUF_HEAP_BUF_SYNC_RW)); in HWTEST_F()
101 ASSERT_EQ(0, DmabufHeapBufferFree(&buffer)); in HWTEST_F()
113 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; in HWTEST_F() local
114 ASSERT_EQ(0, DmabufHeapBufferAlloc(heapFd, &buffer)); in HWTEST_F()
116 void *ptr = mmap(nullptr, BUFFER_SIZE, PROT_READ | PROT_WRITE, MAP_SHARED, buffer.fd, 0); in HWTEST_F()
119 ASSERT_EQ(0, DmabufHeapBufferSyncStart(buffer in HWTEST_F()
183 DmabufHeapBuffer buffer = { .size = 0 }; HWTEST_F() local
198 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; HWTEST_F() local
224 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; HWTEST_F() local
248 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; HWTEST_F() local
280 DmabufHeapBuffer buffer = { .size = BUFFER_SIZE, .heapFlags = 0 }; HWTEST_F() local
[all...]
/arkcompiler/ets_runtime/ecmascript/base/
H A Ddtoa_helper.cpp66 void DtoaHelper::GrisuRound(char *buffer, int len, uint64_t delta, uint64_t rest, uint64_t tenKappa, uint64_t distance) in GrisuRound() argument
70 buffer[len - 1]--; in GrisuRound()
98 void DtoaHelper::DigitGen(const DiyFp &W, const DiyFp &Mp, uint64_t delta, char *buffer, int *len, int *K) in DigitGen() argument
149 buffer[localLen++] = static_cast<char>('0' + static_cast<char>(d)); in DigitGen()
155 GrisuRound(buffer, localLen, delta, tmp, POW10[kappa] << -one.e, distance.f); in DigitGen()
167 buffer[localLen++] = static_cast<char>('0' + d); in DigitGen()
176 GrisuRound(buffer, localLen, delta, p2, one.f, distance.f * POW10[index]); in DigitGen()
185 void DtoaHelper::Grisu(double value, char *buffer, int *length, int *K) in Grisu() argument
198 DigitGen(W, wPlus, wPlus.f - wMinus.f, buffer, length, K); in Grisu()
201 void DtoaHelper::Dtoa(double value, char *buffer, in argument
211 FillDigits32FixedLength(uint32_t number, int requested_length, BufferVector<char> buffer, int* length) FillDigits32FixedLength() argument
221 FillDigits32(uint32_t number, BufferVector<char> buffer, int* length) FillDigits32() argument
244 FillDigits64FixedLength(uint64_t number, [[maybe_unused]] int requested_length, BufferVector<char> buffer, int* length) FillDigits64FixedLength() argument
257 FillDigits64(uint64_t number, BufferVector<char> buffer, int* length) FillDigits64() argument
276 RoundUp(BufferVector<char> buffer, int* length, int* decimal_point) RoundUp() argument
299 FillFractionals(uint64_t fractionals, int exponent, int fractional_count, BufferVector<char> buffer, int* length, int* decimal_point) FillFractionals() argument
324 ASSERT(EXPONENT_64 < -exponent && -exponent <= EXPONENT_128); UInt128 fractionals128 = UInt128(fractionals, 0); fractionals128.Shift(-exponent - EXPONENT_64); int point = 128; for (int i = 0; i < fractional_count; ++i) { if (fractionals128.IsZero()) break; fractionals128.Multiply(5); point--; int digit = fractionals128.DivModPowerOf2(point); buffer[*length] = � + digit; (*length)++; } if (fractionals128.BitAt(point - 1) == 1) { RoundUp(buffer, length, decimal_point); } } } void DtoaHelper::TrimZeros(BufferVector<char> buffer, int* length, int* decimal_point) { while (*length > 0 && buffer[(*length) - 1] == �) { (*length)--; } int first_non_zero = 0; while (first_non_zero < *length && buffer[first_non_zero] == �) { first_non_zero++; } if (first_non_zero != 0) { for (int i = first_non_zero; i < *length; ++i) { buffer[i - first_non_zero] = buffer[i]; } *length -= first_non_zero; *decimal_point -= first_non_zero; } } bool DtoaHelper::FixedDtoa(double v, int fractional_count, BufferVector<char> buffer, int* length, int* decimal_point) { if (v == 0) { buffer[0] = �; buffer[1] = �; *length = 1; *decimal_point = 1; return true; } uint64_t significand = NumberHelper::Significand(v); int exponent = NumberHelper::Exponent(v); if (exponent > 20) return false; if (fractional_count > 20) return false; *length = 0; if (exponent + kDoubleSignificandSize > EXPONENT_64) { const uint64_t kFive17 = 0xB1�2EC5; uint64_t divisor = kFive17; int divisor_power = 17; uint64_t dividend = significand; uint32_t quotient; uint64_t remainder; if (exponent > divisor_power) FillFractionals() argument
412 FillDigits32(static_cast<uint32_t>(integrals), buffer, length); global() local
[all...]
H A Dbit_helper.h33 inline T ReadBuffer(void **buffer, size_t offset) in ReadBuffer() argument
35 T result = *(reinterpret_cast<T *>(*buffer)); in ReadBuffer()
36 *buffer = reinterpret_cast<void *>(reinterpret_cast<uintptr_t>(*buffer) + offset); in ReadBuffer()
41 inline T ReadBuffer(void **buffer) in ReadBuffer() argument
43 T result = *(reinterpret_cast<T *>(*buffer)); in ReadBuffer()
44 *buffer = reinterpret_cast<void *>(reinterpret_cast<uintptr_t>(*buffer) + result.offset_); in ReadBuffer()
48 inline char *ReadBuffer(void **buffer) in ReadBuffer() argument
50 auto result = reinterpret_cast<char *>(*buffer); in ReadBuffer()
56 ReadBufferInSize(void **buffer) ReadBufferInSize() argument
[all...]
/test/xts/hats/kernel/syscalls/fileio/preadv/
H A DPreadvApiTest.cpp75 char buffer[MAX_LEN] = { 0 }; in HWTEST_F() local
78 .iov_base = buffer, in HWTEST_F()
81 .iov_base = &buffer[TEST_LEN], in HWTEST_F()
94 memset_s(buffer, sizeof(buffer), 0, sizeof(buffer)); in HWTEST_F()
100 memset_s(buffer, sizeof(buffer), 0, sizeof(buffer)); in HWTEST_F()
118 char buffer[MAX_LE in HWTEST_F() local
140 char buffer[MAX_LEN] = { 0 }; HWTEST_F() local
164 char buffer[MAX_LEN] = { 0 }; HWTEST_F() local
199 char buffer[MAX_LEN] = { 0 }; HWTEST_F() local
[all...]
/test/xts/acts/multimedia_lite/media_lite_posix/audio_native/src/
H A DActsMediaAudioTest.cpp66 uint8_t *buffer; in HWTEST_F() local
68 audioCapturer->Read(buffer, framesize, false); in HWTEST_F()
69 EXPECT_TRUE(sizeof(buffer) > 0); in HWTEST_F()
92 uint8_t *buffer; in HWTEST_F() local
95 audioCapturer->Read(buffer, framesize, false); in HWTEST_F()
96 EXPECT_TRUE(sizeof(buffer) > 0); in HWTEST_F()
119 uint8_t *buffer; in HWTEST_F() local
122 audioCapturer->Read(buffer, framesize, false); in HWTEST_F()
123 EXPECT_TRUE(sizeof(buffer) > 0); in HWTEST_F()
146 uint8_t *buffer; in HWTEST_F() local
173 uint8_t *buffer; HWTEST_F() local
200 uint8_t *buffer; HWTEST_F() local
227 uint8_t *buffer; HWTEST_F() local
254 uint8_t *buffer; HWTEST_F() local
281 uint8_t *buffer; HWTEST_F() local
308 uint8_t *buffer; HWTEST_F() local
335 uint8_t *buffer; HWTEST_F() local
362 uint8_t *buffer; HWTEST_F() local
389 uint8_t *buffer; HWTEST_F() local
416 uint8_t *buffer; HWTEST_F() local
443 uint8_t *buffer; HWTEST_F() local
470 uint8_t *buffer; HWTEST_F() local
497 uint8_t *buffer; HWTEST_F() local
524 uint8_t *buffer; HWTEST_F() local
551 uint8_t *buffer; HWTEST_F() local
578 uint8_t *buffer; HWTEST_F() local
605 uint8_t *buffer; HWTEST_F() local
632 uint8_t *buffer; HWTEST_F() local
659 uint8_t *buffer; HWTEST_F() local
686 uint8_t *buffer; HWTEST_F() local
713 uint8_t *buffer; HWTEST_F() local
740 uint8_t *buffer; HWTEST_F() local
767 uint8_t *buffer; HWTEST_F() local
794 uint8_t *buffer; HWTEST_F() local
821 uint8_t *buffer; HWTEST_F() local
848 uint8_t *buffer; HWTEST_F() local
875 uint8_t *buffer; HWTEST_F() local
902 uint8_t *buffer; HWTEST_F() local
929 uint8_t *buffer; HWTEST_F() local
956 uint8_t *buffer; HWTEST_F() local
983 uint8_t *buffer; HWTEST_F() local
1010 uint8_t *buffer; HWTEST_F() local
1037 uint8_t *buffer; HWTEST_F() local
1064 uint8_t *buffer; HWTEST_F() local
1091 uint8_t *buffer; HWTEST_F() local
1118 uint8_t *buffer; HWTEST_F() local
1145 uint8_t *buffer; HWTEST_F() local
1172 uint8_t *buffer; HWTEST_F() local
1199 uint8_t *buffer; HWTEST_F() local
1226 uint8_t *buffer; HWTEST_F() local
1253 uint8_t *buffer; HWTEST_F() local
1280 uint8_t *buffer; HWTEST_F() local
1307 uint8_t *buffer; HWTEST_F() local
1334 uint8_t *buffer; HWTEST_F() local
1361 uint8_t *buffer; HWTEST_F() local
1388 uint8_t *buffer; HWTEST_F() local
1415 uint8_t *buffer; HWTEST_F() local
1442 uint8_t *buffer; HWTEST_F() local
1469 uint8_t *buffer; HWTEST_F() local
1496 uint8_t *buffer; HWTEST_F() local
1523 uint8_t *buffer; HWTEST_F() local
1550 uint8_t *buffer; HWTEST_F() local
1577 uint8_t *buffer; HWTEST_F() local
1604 uint8_t *buffer; HWTEST_F() local
1631 uint8_t *buffer; HWTEST_F() local
1658 uint8_t *buffer; HWTEST_F() local
1685 uint8_t *buffer; HWTEST_F() local
1712 uint8_t *buffer; HWTEST_F() local
1739 uint8_t *buffer; HWTEST_F() local
1766 uint8_t *buffer; HWTEST_F() local
1793 uint8_t *buffer; HWTEST_F() local
1820 uint8_t *buffer; HWTEST_F() local
1847 uint8_t *buffer; HWTEST_F() local
1874 uint8_t *buffer; HWTEST_F() local
1901 uint8_t *buffer; HWTEST_F() local
1928 uint8_t *buffer; HWTEST_F() local
1955 uint8_t *buffer; HWTEST_F() local
1982 uint8_t *buffer; HWTEST_F() local
2009 uint8_t *buffer; HWTEST_F() local
2036 uint8_t *buffer; HWTEST_F() local
2063 uint8_t *buffer; HWTEST_F() local
2090 uint8_t *buffer; HWTEST_F() local
2117 uint8_t *buffer; HWTEST_F() local
2144 uint8_t *buffer; HWTEST_F() local
2171 uint8_t *buffer; HWTEST_F() local
2198 uint8_t *buffer; HWTEST_F() local
[all...]
/arkcompiler/runtime_core/libpandabase/tests/ringbuf/
H A Dlock_free_ring_buffer_test.cpp33 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
34 ASSERT_TRUE(buffer.IsEmpty()); in TEST()
36 buffer.Push(123); in TEST()
37 ASSERT_FALSE(buffer.IsEmpty()); in TEST()
38 buffer.Pop(); in TEST()
39 ASSERT_TRUE(buffer.IsEmpty()); in TEST()
44 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
46 buffer.Push(i); in TEST()
48 // in buffer can be maximum RING_BUFFER_SIZE - 1 elements in TEST()
49 ASSERT_FALSE(buffer in TEST()
57 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
81 PopElementsFromBuffer(LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> *buffer, std::atomic<bool> *pop_thread_started, std::atomic<bool> *pop_thread_finished, size_t *pop_sum) PopElementsFromBuffer() argument
99 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
[all...]
/arkcompiler/runtime_core/static_core/libpandabase/tests/ringbuf/
H A Dlock_free_ring_buffer_test.cpp33 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
34 ASSERT_TRUE(buffer.IsEmpty()); in TEST()
37 buffer.Push(123); in TEST()
38 ASSERT_FALSE(buffer.IsEmpty()); in TEST()
39 buffer.Pop(); in TEST()
40 ASSERT_TRUE(buffer.IsEmpty()); in TEST()
45 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; in TEST() local
47 buffer.Push(i); in TEST()
49 // in buffer can be maximum RING_BUFFER_SIZE - 1 elements in TEST()
50 ASSERT_FALSE(buffer in TEST()
59 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
84 PopElementsFromBuffer(LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> *buffer, std::atomic<bool> *popThreadStarted, std::atomic<bool> *popThreadFinished, size_t *popSum) PopElementsFromBuffer() argument
103 LockFreeBuffer<size_t, DEFAULT_BUFFER_SIZE> buffer; TEST() local
[all...]
/test/xts/acts/graphic/graphicnapitest/
H A DNativeBufferTest.cpp49 static inline OH_NativeBuffer* buffer = nullptr; member in OHOS::Rosen::NativeBufferTest
54 buffer = nullptr; in SetUpTestCase()
59 buffer = nullptr; in TearDownTestCase()
71 buffer = OH_NativeBuffer_Alloc(nullptr); in HWTEST_F()
72 ASSERT_EQ(buffer, nullptr); in HWTEST_F()
84 buffer = OH_NativeBuffer_Alloc(&config); in HWTEST_F()
85 ASSERT_NE(buffer, nullptr); in HWTEST_F()
110 uint32_t id = OH_NativeBuffer_GetSeqNum(buffer); in HWTEST_F()
123 OH_NativeBuffer_GetConfig(buffer, &checkConfig); in HWTEST_F()
169 int32_t ret = OH_NativeBuffer_Reference(buffer); in HWTEST_F()
564 OH_NativeBuffer *buffer = (OH_NativeBuffer *)0xFFFFFFFF; HWTEST_F() local
[all...]
/arkcompiler/runtime_core/verifier/tests/
H A Dverify_constant_pool_tests.cpp80 std::vector<unsigned char> buffer(std::istreambuf_iterator<char>(base_file), {}); in HWTEST_F()
85 for (size_t i = buffer.size() - 1; i >= 0; --i) { in HWTEST_F()
86 if (buffer[i] == method_id[0] && buffer[i + 1] == method_id[1]) { in HWTEST_F()
87 buffer[i] = static_cast<unsigned char>(new_method_id[0]); in HWTEST_F()
88 buffer[i + 1] = static_cast<unsigned char>(new_method_id[1]); in HWTEST_F()
94 GenerateModifiedAbc(buffer, target_file_name); in HWTEST_F()
143 std::vector<unsigned char> buffer(std::istreambuf_iterator<char>(base_file), {}); in HWTEST_F()
148 for (size_t i = 0; i < buffer.size(); ++i) { in HWTEST_F()
149 if (buffer[ in HWTEST_F()
[all...]
H A Dutils.cpp23 void GenerateModifiedAbc(const std::vector<unsigned char> &buffer, const std::string &filename) in GenerateModifiedAbc() argument
31 abc_file.write(reinterpret_cast<const char *>(buffer.data()), buffer.size()); in GenerateModifiedAbc()
44 void ModifyBuffer(std::unordered_map<uint32_t, uint32_t> &literal_map, std::vector<unsigned char> &buffer) in ModifyBuffer() argument
50 for (size_t i = literal_id; i < buffer.size(); ++i) { in ModifyBuffer()
51 if (buffer[i] == inner_id[0] && buffer[i+1] == inner_id[1]) { in ModifyBuffer()
53 // The abc is tampered with by setting buffer[i + 1] to buffer[i] and buffer[ in ModifyBuffer()
[all...]
H A Dverify_register_index_test.cpp77 std::vector<unsigned char> buffer(std::istreambuf_iterator<char>(base_file), {}); in HWTEST_F()
81 for (size_t i = 0; i < buffer.size() - 2; i++) { in HWTEST_F()
82 if (buffer[i] == op_code[0] && buffer[i+1] == op_code[1]) { in HWTEST_F()
83 buffer[i + 1] = static_cast<unsigned char>(new_reg_id); in HWTEST_F()
88 GenerateModifiedAbc(buffer, tar_file_name); in HWTEST_F()
120 std::vector<unsigned char> buffer(std::istreambuf_iterator<char>(base_file), {}); in HWTEST_F()
124 for (size_t i = 0; i < buffer.size() - 4; i++) { in HWTEST_F()
125 if (buffer[i] == inst[0] && buffer[ in HWTEST_F()
[all...]
/arkcompiler/runtime_core/assembler/
H A Dlexer.cpp170 LOG(DEBUG, ASSEMBLER) << std::string_view(&*(curr_line_->buffer.begin() + curr_line_->pos), in TokenizeString()
199 if (FindDelim(curr_line_->buffer[beg]) != Token::Type::ID_BAD) { /* delimiter */ in LexGetType()
200 return FindDelim(curr_line_->buffer[beg]); in LexGetType()
203 std::string_view p(&*(curr_line_->buffer.begin() + beg), end - beg); in LexGetType()
217 if (IsQuote(curr_line_->buffer[beg])) { in LexGetType()
228 char quote = curr_line_->buffer[curr_line_->pos]; in LexString()
233 char c = curr_line_->buffer[curr_line_->pos]; in LexString()
249 if (curr_line_->buffer[curr_line_->pos] != quote) { in LexString()
252 curr_line_->buffer); in LexString()
282 << std::string_view(&*(curr_line_->buffer in LexTokens()
[all...]
/test/xts/acts/distributed_schedule_lite/distributed_schedule_posix/src/
H A DMsgParserFuncTest.cpp26 static int8_t RunTest(const uint8_t *buffer, uint16_t bufferLen, const TlvParseCallback onTlvParseDone, in RunTest() argument
36 interInfo.payload = buffer; in RunTest()
69 uint8_t buffer[] = { in HWTEST_F() local
88 RunTest(buffer, sizeof(buffer), onTlvParseDone, nullptr); in HWTEST_F()
98 uint8_t buffer[] = { in HWTEST_F() local
111 int8_t resultCode = RunTest(nullptr, sizeof(buffer), onTlvParseDone, nullptr); in HWTEST_F()
121 uint8_t buffer[] = { in HWTEST_F() local
129 int8_t resultCode = RunTest(buffer, sizeof(buffer), onTlvParseDon in HWTEST_F()
139 uint8_t buffer[] = { HWTEST_F() local
162 uint8_t buffer[] = { }; HWTEST_F() local
179 uint8_t buffer[] = { HWTEST_F() local
197 uint8_t buffer[] = { HWTEST_F() local
217 uint8_t buffer[] = { HWTEST_F() local
238 uint8_t buffer[] = { HWTEST_F() local
262 uint8_t buffer[] = { HWTEST_F() local
283 uint8_t buffer[] = { HWTEST_F() local
304 uint8_t buffer[] = { HWTEST_F() local
327 uint8_t buffer[] = { HWTEST_F() local
352 uint8_t buffer[] = { HWTEST_F() local
377 uint8_t buffer[] = { HWTEST_F() local
401 uint8_t buffer[] = { HWTEST_F() local
420 uint8_t buffer[] = { HWTEST_F() local
441 uint8_t buffer[] = { HWTEST_F() local
464 uint8_t buffer[] = { HWTEST_F() local
488 uint8_t buffer[] = { HWTEST_F() local
510 uint8_t buffer[] = { HWTEST_F() local
533 uint8_t buffer[] = { HWTEST_F() local
556 uint8_t buffer[] = { HWTEST_F() local
573 uint8_t buffer[] = { HWTEST_F() local
593 uint8_t buffer[] = { HWTEST_F() local
615 uint8_t buffer[] = { HWTEST_F() local
639 uint8_t buffer[] = { HWTEST_F() local
662 uint8_t buffer[] = { HWTEST_F() local
685 uint8_t buffer[] = { HWTEST_F() local
708 uint8_t buffer[] = { HWTEST_F() local
[all...]
/test/testfwk/developer_test/aw/cxx/hwext/
H A Dperf.cpp310 char buffer[ID_PROPERTY_LENGTH] = {0}; in SaveResult() local
319 (void)memset_s(buffer, sizeof(buffer), 0, sizeof(buffer)); in SaveResult()
320 if (snprintf_s(buffer, sizeof(buffer), sizeof(buffer) - 1, "%g", m_dbBaseLine) > 0) { in SaveResult()
321 m_pTester->RecordProperty("baseline", buffer); in SaveResult()
324 (void)memset_s(buffer, sizeof(buffer), in SaveResult()
[all...]
/test/xts/hats/hdf/camera/cameraHdi/buffer_manager/
H A Dbuffer_manager_utest.cpp66 OHOS::SurfaceBuffer* buffer = consumer->AcquireBuffer(); in HWTEST_F()
67 if (buffer != nullptr) { in HWTEST_F()
68 consumer->ReleaseBuffer(buffer); in HWTEST_F()
69 std::cout << "receive a buffer ..." << std::endl; in HWTEST_F()
87 sptr<SurfaceBuffer> buffer = nullptr; in HWTEST_F()
88 consumer->AcquireBuffer(buffer, flushFence, timestamp, damage); in HWTEST_F()
89 if (buffer != nullptr) { in HWTEST_F()
90 SurfaceError ret = consumer->ReleaseBuffer(buffer, -1); in HWTEST_F()
92 std::cout << "receive a buffer ..." << std::endl; in HWTEST_F()
161 std::shared_ptr<IBuffer> buffer; in HWTEST_F() local
228 auto buffer = bufferPool->AcquireBuffer(); HWTEST_F() local
282 std::shared_ptr<IBuffer> buffer = std::make_shared<ImageBuffer>(); HWTEST_F() local
573 std::shared_ptr<IBuffer> buffer = nullptr; EnqueueBufferNonBlock() local
594 DequeueBuffer(std::shared_ptr<IBuffer>& buffer) DequeueBuffer() argument
730 DeliverBuffer(std::shared_ptr<IBuffer>& buffer) DeliverBuffer() argument
783 Deliver(std::shared_ptr<IBuffer>& buffer) Deliver() argument
792 Receive(std::shared_ptr<IBuffer>& buffer) Receive() argument
805 Process(std::shared_ptr<IBuffer>& buffer) Process() argument
818 Deliver(std::shared_ptr<IBuffer>& buffer) Deliver() argument
827 Process(std::shared_ptr<IBuffer>& buffer) Process() argument
[all...]
/test/xts/device_attest/services/core/adapter/
H A Dattest_adapter.c51 int32_t AttestReadAuthStatus(char* buffer, uint32_t bufferLen) in AttestReadAuthStatus() argument
53 return OEMReadAuthStatus(buffer, bufferLen); in AttestReadAuthStatus()
89 int32_t AttestWriteNetworkConfig(const char* buffer, uint32_t bufferLen) in AttestWriteNetworkConfig() argument
91 return OEMWriteNetworkConfig(buffer, bufferLen); in AttestWriteNetworkConfig()
94 int32_t AttestReadNetworkConfig(char* buffer, uint32_t bufferLen) in AttestReadNetworkConfig() argument
96 return OEMReadNetworkConfig(buffer, bufferLen); in AttestReadNetworkConfig()
99 int32_t AttestReadDefaultNetworkConfig(char* buffer, uint32_t bufferLen) in AttestReadDefaultNetworkConfig() argument
101 return OEMReadDefaultNetworkConfig(buffer, bufferLen); in AttestReadDefaultNetworkConfig()
109 int32_t AttestReadAuthResultCode(char* buffer, uint32_t bufferLen) in AttestReadAuthResultCode() argument
111 return OEMReadAuthResultCode(buffer, bufferLe in AttestReadAuthResultCode()
119 AttestReadFullLoadStatus(char* buffer, uint32_t bufferLen) AttestReadFullLoadStatus() argument
[all...]
/test/xts/hats/kernel/syscalls/fileio/lsetxattr/
H A DLsetxattrApiTest.cpp62 int GetExtendedAttribute(const char* linkPath, const char* attrName, char* buffer, size_t bufferSize) in GetExtendedAttribute() argument
64 ssize_t ret = lgetxattr(linkPath, attrName, buffer, bufferSize); in GetExtendedAttribute()
68 buffer[ret] = '\0'; in GetExtendedAttribute()
108 char buffer[64] = {0}; in HWTEST_F() local
109 ret = GetExtendedAttribute(targetFilePath, attrName, buffer, sizeof(buffer)); in HWTEST_F()
112 ret = strncmp(attrValue, buffer, strlen(attrValue)); in HWTEST_F()
141 char buffer[64] = {0}; in HWTEST_F() local
142 ret = GetExtendedAttribute(targetFilePath, attrName1, buffer, sizeof(buffer)); in HWTEST_F()
187 char buffer[64] = {0}; HWTEST_F() local
257 char buffer[64] = {0}; HWTEST_F() local
593 char buffer[64] = {0}; HWTEST_F() local
[all...]
/test/xts/hats/ai/nnrt/hdi/v1_0/common/
H A Dhdi_nnrt_test_utils.cpp122 printf("[NNRtTest] [ConvertModel] allocate tensor buffer failed after get const tensor size,"\ in ConvertModel()
146 OHOS::HDI::Nnrt::V1_0::SharedBuffer buffer{NNRT_INVALID_FD, 0, 0, 0}; in CreateIOTensor()
147 int ret = device->AllocateBuffer(ADDEND_BUFFER_LENGTH, buffer); in CreateIOTensor()
148 if (ret != HDF_SUCCESS || buffer.fd == NNRT_INVALID_FD) { in CreateIOTensor()
149 printf("[NNRtTest] [CreateIOTensor] allocate buffer error. ret: %d, fd: %d\n", ret, buffer.fd); in CreateIOTensor()
155 .data = buffer}; in CreateIOTensor()
165 OHOS::HDI::Nnrt::V1_0::SharedBuffer buffer{NNRT_INVALID_FD, 0, 0, 0}; in CreateInputIOTensor()
166 auto ret = device->AllocateBuffer(length, buffer); in CreateInputIOTensor()
168 if (ret != HDF_SUCCESS || buffer in CreateInputIOTensor()
219 UnmapMemory(float* buffer) UnmapMemory() argument
228 SetData(float* buffer, size_t length, float* data) SetData() argument
288 PrintTensor(const float *buffer, size_t length) PrintTensor() argument
[all...]
/test/xts/hats/ai/nnrt/hdi/v2_0/common/
H A Dhdi_nnrt_test_utils.cpp122 printf("[NNRtTest] [ConvertModel] allocate tensor buffer failed after get const tensor size,"\ in ConvertModel()
146 OHOS::HDI::Nnrt::V2_0::SharedBuffer buffer{NNRT_INVALID_FD, 0, 0, 0}; in CreateIOTensor()
147 int ret = device->AllocateBuffer(ADDEND_BUFFER_LENGTH, buffer); in CreateIOTensor()
148 if (ret != HDF_SUCCESS || buffer.fd == NNRT_INVALID_FD) { in CreateIOTensor()
149 printf("[NNRtTest] [CreateIOTensor] allocate buffer error. ret: %d, fd: %d\n", ret, buffer.fd); in CreateIOTensor()
155 .data = buffer}; in CreateIOTensor()
165 OHOS::HDI::Nnrt::V2_0::SharedBuffer buffer{NNRT_INVALID_FD, 0, 0, 0}; in CreateInputIOTensor()
166 auto ret = device->AllocateBuffer(length, buffer); in CreateInputIOTensor()
168 if (ret != HDF_SUCCESS || buffer in CreateInputIOTensor()
219 UnmapMemory(float* buffer) UnmapMemory() argument
228 SetData(float* buffer, size_t length, float* data) SetData() argument
288 PrintTensor(const float *buffer, size_t length) PrintTensor() argument
[all...]
/test/ostest/wukong/common/include/
H A Dspecial_test_object.h55 char buffer[50]; in toString() local
58 result = sprintf_s(buffer, sizeof(buffer), "Swap: (%d, %d) -> (%d, %d)", endX_, endY_, startX_, startY_); in toString()
60 result = sprintf_s(buffer, sizeof(buffer), "Swap: (%d, %d) -> (%d, %d)", startX_, startY_, endX_, endY_); in toString()
65 return std::string(buffer); in toString()
84 char buffer[50]; in toString() local
85 int result = sprintf_s(buffer, sizeof(buffer), "Point: (%d, %d)", x_, y_); in toString()
89 return std::string(buffer); in toString()
104 char buffer[50]; toString() local
[all...]
/test/xts/acts/ai/neural_network_runtime/v2_0/common/
H A Dmock_idevice.cpp238 int32_t MockIDevice::AllocateBuffer(uint32_t length, SharedBuffer &buffer) in AllocateBuffer() argument
241 buffer.fd = AshmemCreate("allocateBuffer", length); in AllocateBuffer()
242 buffer.bufferSize = AshmemGetSize(buffer.fd); in AllocateBuffer()
243 buffer.offset = 0; in AllocateBuffer()
244 buffer.dataSize = length; in AllocateBuffer()
246 AshmemSetProt(buffer.fd, PROT_READ | PROT_WRITE); in AllocateBuffer()
247 m_fds.emplace(buffer.fd); in AllocateBuffer()
248 m_bufferFd = buffer.fd; in AllocateBuffer()
252 int32_t MockIDevice::ReleaseBuffer(const SharedBuffer &buffer) in ReleaseBuffer() argument
315 SharedBuffer buffer; ExportModelCache() local
[all...]

Completed in 15 milliseconds

12345678910>>...66