Searched refs:array (Results 1 - 25 of 100) sorted by relevance

1234

/system/bt/osi/src/
H A Darray.cc21 #include "osi/include/array.h"
38 static bool grow(array_t* array);
45 array_t* array = static_cast<array_t*>( local
48 array->element_size = element_size;
49 array->capacity = INTERNAL_ELEMENTS;
50 array->data = array->internal_storage;
51 return array;
54 void array_free(array_t* array) { argument
55 if (!array) retur
62 array_ptr(const array_t* array) argument
64 array_at(const array_t* array, size_t index) argument
70 array_length(const array_t* array) argument
75 array_append_value(array_t* array, uint32_t value) argument
79 array_append_ptr(array_t* array, void* data) argument
96 grow(array_t* array) argument
[all...]
/system/chre/util/include/chre/util/
H A Dmacros.h21 * Obtains the number of elements in a C-style array.
23 #define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0]))
24 #define ARRAY_END(array) (array + ARRAY_SIZE(array))
/system/bt/osi/test/
H A Darray_test.cc5 #include "osi/include/array.h"
10 array_t* array = array_new(4); local
11 ASSERT_TRUE(array != NULL);
12 array_free(array);
18 array_t* array = array_new(4); local
19 EXPECT_DEATH(array_ptr(array), "");
20 array_free(array);
24 array_t* array = array_new(4); local
25 EXPECT_DEATH(array_at(array, 1), "");
26 array_free(array);
30 array_t* array = array_new(sizeof(int)); local
42 array_t* array = array_new(sizeof(int)); local
59 array_t* array = array_new(128); local
[all...]
/system/bt/osi/include/
H A Darray.h27 // Returns a new array object that stores elements of size |element_size|. The
32 // Frees an array that was allocated with |array_new|. |array| may be NULL.
33 void array_free(array_t* array);
35 // Returns a pointer to the first stored element in |array|. |array| must not be
37 void* array_ptr(const array_t* array);
39 // Returns a pointer to the |index|th element of |array|. |index| must be less
40 // than the array's length. |array| mus
[all...]
/system/libvintf/include/vintf/
H A DHalFormat.h23 #include <array>
33 static const std::array<std::string, 2> gHalFormatStrings = {
H A DSchemaType.h22 #include <array>
32 static const std::array<std::string, 2> gSchemaTypeStrings = {
H A DXmlSchemaFormat.h20 #include <array>
31 static const std::array<std::string, 2> gXmlSchemaFormatStrings = {{
H A DKernelConfigType.h22 #include <array>
34 static const std::array<std::string, 4> gKernelConfigTypeStrings = {
H A DTransport.h23 #include <array>
34 static const std::array<std::string, 3> gTransportStrings = {
H A DTristate.h22 #include <array>
33 static const std::array<std::string, 3> gTristateStrings = {
H A DArch.h23 #include <array>
35 static const std::array<std::string, 4> gArchStrings = {
/system/chre/util/tests/
H A Dheap_test.cc5 #include <array>
28 std::array<int, MaxSize> array; local
29 std::array<int, MaxSize> array_sorted;
32 array[i] = std::rand();
33 array_sorted[i] = array[i];
36 // make sure the popped data is in the right order of various array sizes.
39 v.push_back(array[i]);
68 std::array<int, MaxSize> array; local
[all...]
/system/connectivity/wifilogd/
H A Dbyte_buffer.h20 #include <array>
62 std::array<uint8_t, SizeBytes> raw_buffer_;
H A Dmain_loop.cpp17 #include <array>
52 std::array<uint8_t, protocol::kMaxMessageSize> input_buf;
/system/netd/libnetdutils/
H A DSocket.cpp26 std::array<char, INET6_ADDRSTRLEN> out = {};
/system/extras/simpleperf/
H A Dperf_clock.cpp58 TryMmap array[TRY_MMAP_COUNT]; local
63 array[i].start_system_time_in_ns = GetSystemClock();
64 array[i].mmap_start_addr =
66 if (array[i].mmap_start_addr == MAP_FAILED) {
72 array[i].end_system_time_in_ns = GetSystemClock();
78 array[i].end_system_time_in_ns - array[i].start_system_time_in_ns;
83 munmap(array[i].mmap_start_addr, 4096);
86 reinterpret_cast<uint64_t>(array[best_index].mmap_start_addr);
89 thread_arg->system_time_in_ns = array[best_inde
[all...]
/system/connectivity/wifilogd/tests/
H A Dmemory_reader_unittest.cpp17 #include <array>
31 constexpr std::array<uint8_t, 1> buffer{};
37 constexpr std::array<uint8_t, 0> buffer{};
48 constexpr std::array<uint8_t, 3> buffer{{1, 2, 3}};
62 constexpr std::array<uint8_t, 3> buffer{{1, 2, 3}};
110 constexpr std::array<uint8_t, 1024> buffer{};
116 constexpr std::array<uint8_t, 1024> buffer{};
122 constexpr std::array<uint8_t, 1024> buffer{};
131 constexpr std::array<uint8_t, 1> buffer{};
137 constexpr std::array<uint8_
[all...]
H A Dos_unittest.cpp17 #include <array>
195 std::array<uint8_t, 8192> buffer{};
208 std::array<uint8_t, kReadBufferSize> buffer{};
221 std::array<uint8_t, kReadBufferSize> buffer{};
232 std::array<uint8_t, 8192> buffer{};
244 std::array<uint8_t, 8192> buffer{};
255 constexpr std::array<uint8_t, 8192> buffer{};
266 constexpr std::array<uint8_t, 8192> buffer{};
276 constexpr std::array<uint8_t, 0> buffer{};
286 constexpr std::array<uint8_
[all...]
/system/tools/aidl/tests/
H A Daidl_test_client_file_descriptors.cpp142 vector<unique_fd> array; local
143 array.resize(2);
145 if (!DoPipe(&array[0], &array[1])) {
152 status = s->ReverseFileDescriptorArray(array, &repeated, &reversed);
155 cerr << "Could not reverse file descriptor array." << endl;
160 DoWrite(FdByName(array[1]), "First") &&
/system/core/base/include/android-base/
H A Dmacros.h58 // The arraysize(arr) macro returns the # of elements in an array arr.
63 // One caveat is that arraysize() doesn't accept any array of an
73 char(&ArraySizeHelper(T(&array)[N]))[N]; // NOLINT(readability/casting)
75 #define arraysize(array) (sizeof(ArraySizeHelper(array)))
97 // the array) and sizeof(*(arr)) (the # of bytes in one array
99 // indeed an array, in which case the division result is the # of
100 // elements in the array. Otherwise, arr cannot possibly be an array,
[all...]
/system/core/libutils/
H A DVectorImpl.cpp126 ssize_t VectorImpl::insertArrayAt(const void* array, size_t index, size_t length) argument
132 _do_copy(where, array, length);
137 ssize_t VectorImpl::appendArray(const void* array, size_t length) argument
139 return insertArrayAt(array, size(), length);
179 void* array = const_cast<void*>(arrayImpl()); local
183 void* item = reinterpret_cast<char*>(array) + mItemSize*(i);
184 void* curr = reinterpret_cast<char*>(array) + mItemSize*(i-1);
188 // we're going to have to modify the array...
189 array = editArrayImpl();
190 if (!array) retur
[all...]
/system/chre/apps/chqts/src/shared/
H A Dnano_string_test.cc155 char array[kAsciiLen + 1]; local
156 array[kAsciiLen] = kUnsetValue;
157 uint32ToHexAscii(array, sizeof(array), value);
158 EXPECT_EQ(kUnsetValue, array[kAsciiLen]);
159 array[kAsciiLen] = '\0';
160 EXPECT_STREQ(str, array);
/system/libhidl/
H A Dtest_main.cpp194 int32_t array[] = {5, 6, 7};
195 vector<int32_t> v(array, array + 3);
201 EXPECT_ARRAYEQ(hv1, array, 3);
211 EXPECT_ARRAYEQ(v3, array, v3.size());
215 int32_t array[] = {5, 6, 7}; local
216 android::hardware::hidl_vec<int32_t> hv1 = std::vector<int32_t>(array, array + 3);
253 int32_t array[] = {5, 6, 7};
254 hidl_vec<int32_t> hv1 = std::vector<int32_t>(array, arra
[all...]
/system/core/include/utils/
H A DVector.h104 * C-style array access
108 inline const TYPE* array() const;
124 * modifying the array
143 //! insert an array at a given index
144 ssize_t insertArrayAt(const TYPE* array, size_t index, size_t length);
146 //! append an array at the end of this vector
147 ssize_t appendArray(const TYPE* array, size_t length);
182 * sort (stable) the array
204 inline const_iterator begin() const { return array(); }
205 inline const_iterator end() const { return array()
278 const TYPE* Vector<TYPE>::array() const { function in class:android::Vector
327 insertArrayAt(const TYPE* array, size_t index, size_t length) argument
332 appendArray(const TYPE* array, size_t length) argument
[all...]
/system/core/libutils/include/utils/
H A DVector.h104 * C-style array access
108 inline const TYPE* array() const;
124 * modifying the array
143 //! insert an array at a given index
144 ssize_t insertArrayAt(const TYPE* array, size_t index, size_t length);
146 //! append an array at the end of this vector
147 ssize_t appendArray(const TYPE* array, size_t length);
182 * sort (stable) the array
204 inline const_iterator begin() const { return array(); }
205 inline const_iterator end() const { return array()
278 const TYPE* Vector<TYPE>::array() const { function in class:android::Vector
327 insertArrayAt(const TYPE* array, size_t index, size_t length) argument
332 appendArray(const TYPE* array, size_t length) argument
[all...]

Completed in 649 milliseconds

1234