Home
last modified time | relevance | path

Searched refs:value (Results 1 – 25 of 992) sorted by relevance

12345678910>>...40

/system/core/libutils/include/utils/
DBitSet.h36 uint32_t value; member
38 inline BitSet32() : value(0UL) { } in BitSet32()
39 explicit inline BitSet32(uint32_t value) : value(value) { } in BitSet32()
45 inline void clear() { clear(value); } in clear()
47 static inline void clear(uint32_t& value) { value = 0UL; } in clear()
50 inline uint32_t count() const { return count(value); } in count()
52 static inline uint32_t count(uint32_t value) { in count()
53 return static_cast<uint32_t>(__builtin_popcountl(value)); in count()
57 inline bool isEmpty() const { return isEmpty(value); } in isEmpty()
59 static inline bool isEmpty(uint32_t value) { return ! value; } in isEmpty()
[all …]
DTypeHelpers.h35 template <typename T> struct trait_trivial_ctor { enum { value = false }; }; enumerator
36 template <typename T> struct trait_trivial_dtor { enum { value = false }; }; enumerator
37 template <typename T> struct trait_trivial_copy { enum { value = false }; }; enumerator
38 template <typename T> struct trait_trivial_move { enum { value = false }; }; enumerator
39 template <typename T> struct trait_pointer { enum { value = false }; }; enumerator
40 template <typename T> struct trait_pointer<T*> { enum { value = true }; };
46 is_pointer = trait_pointer<TYPE>::value,
48 has_trivial_ctor = is_pointer || trait_trivial_ctor<TYPE>::value,
50 has_trivial_dtor = is_pointer || trait_trivial_dtor<TYPE>::value,
52 has_trivial_copy = is_pointer || trait_trivial_copy<TYPE>::value,
[all …]
/system/core/libunwindstack/tests/
DDwarfMemoryTest.cpp38 void GetEncodedSizeTest(uint8_t value, size_t expected);
85 uint64_t value; in TEST_F() local
90 ASSERT_TRUE(dwarf_mem_->ReadSigned<int8_t>(&value)); in TEST_F()
91 ASSERT_EQ(static_cast<int8_t>(-10), static_cast<int8_t>(value)); in TEST_F()
92 ASSERT_TRUE(dwarf_mem_->ReadSigned<int8_t>(&value)); in TEST_F()
93 ASSERT_EQ(static_cast<int8_t>(200), static_cast<int8_t>(value)); in TEST_F()
99 ASSERT_TRUE(dwarf_mem_->ReadSigned<int16_t>(&value)); in TEST_F()
100 ASSERT_EQ(static_cast<int16_t>(-1000), static_cast<int16_t>(value)); in TEST_F()
101 ASSERT_TRUE(dwarf_mem_->ReadSigned<int16_t>(&value)); in TEST_F()
102 ASSERT_EQ(static_cast<int16_t>(50100), static_cast<int16_t>(value)); in TEST_F()
[all …]
DMemoryFake.h39 void SetMemoryBlock(uint64_t addr, size_t length, uint8_t value);
41 void SetData8(uint64_t addr, uint8_t value) { in SetData8() argument
42 SetMemory(addr, &value, sizeof(value)); in SetData8()
45 void SetData16(uint64_t addr, uint16_t value) { in SetData16() argument
46 SetMemory(addr, &value, sizeof(value)); in SetData16()
49 void SetData32(uint64_t addr, uint32_t value) { in SetData32() argument
50 SetMemory(addr, &value, sizeof(value)); in SetData32()
53 void SetData64(uint64_t addr, uint64_t value) { in SetData64() argument
54 SetMemory(addr, &value, sizeof(value)); in SetData64()
/system/core/fs_mgr/libfs_avb/tests/
Dutil_test.cpp41 uint8_t value; in TEST() local
43 EXPECT_TRUE(NibbleValue('0', &value)); in TEST()
44 EXPECT_EQ(0, value); in TEST()
45 EXPECT_TRUE(NibbleValue('1', &value)); in TEST()
46 EXPECT_EQ(1, value); in TEST()
47 EXPECT_TRUE(NibbleValue('2', &value)); in TEST()
48 EXPECT_EQ(2, value); in TEST()
49 EXPECT_TRUE(NibbleValue('3', &value)); in TEST()
50 EXPECT_EQ(3, value); in TEST()
51 EXPECT_TRUE(NibbleValue('4', &value)); in TEST()
[all …]
/system/core/libstats/push_compat/include/
Dstats_event_list.h29 int android_log_write_char_array(android_log_context ctx, const char* value, size_t len);
87 stats_event_list& operator<<(int32_t value) {
88 int retval = android_log_write_int32(ctx, value);
95 stats_event_list& operator<<(uint32_t value) {
96 int retval = android_log_write_int32(ctx, static_cast<int32_t>(value));
103 stats_event_list& operator<<(bool value) {
104 int retval = android_log_write_int32(ctx, value ? 1 : 0);
111 stats_event_list& operator<<(int64_t value) {
112 int retval = android_log_write_int64(ctx, value);
119 stats_event_list& operator<<(uint64_t value) {
[all …]
/system/core/libstats/socket/include/
Dstats_event_list.h29 int android_log_write_char_array(android_log_context ctx, const char* value, size_t len);
85 stats_event_list& operator<<(int32_t value) {
86 int retval = android_log_write_int32(ctx, value);
93 stats_event_list& operator<<(uint32_t value) {
94 int retval = android_log_write_int32(ctx, static_cast<int32_t>(value));
101 stats_event_list& operator<<(bool value) {
102 int retval = android_log_write_int32(ctx, value ? 1 : 0);
109 stats_event_list& operator<<(int64_t value) {
110 int retval = android_log_write_int64(ctx, value);
117 stats_event_list& operator<<(uint64_t value) {
[all …]
/system/core/liblog/include/log/
Dlog_event_list.h71 int android_log_write_int32(android_log_context ctx, int32_t value);
72 int android_log_write_int64(android_log_context ctx, int64_t value);
73 int android_log_write_string8(android_log_context ctx, const char* value);
74 int android_log_write_string8_len(android_log_context ctx, const char* value,
76 int android_log_write_float32(android_log_context ctx, float value);
146 android_log_event_list& operator<<(int32_t value) {
147 int retval = android_log_write_int32(ctx, value);
152 android_log_event_list& operator<<(uint32_t value) {
153 int retval = android_log_write_int32(ctx, static_cast<int32_t>(value));
158 android_log_event_list& operator<<(bool value) {
[all …]
/system/update_engine/update_manager/
Dboxed_value.cc46 string BoxedValue::ValuePrinter<string>(const void* value) { in ValuePrinter() argument
47 const string* val = reinterpret_cast<const string*>(value); in ValuePrinter()
52 string BoxedValue::ValuePrinter<int>(const void* value) { in ValuePrinter() argument
53 const int* val = reinterpret_cast<const int*>(value); in ValuePrinter()
58 string BoxedValue::ValuePrinter<unsigned int>(const void* value) { in ValuePrinter() argument
59 const unsigned int* val = reinterpret_cast<const unsigned int*>(value); in ValuePrinter()
64 string BoxedValue::ValuePrinter<int64_t>(const void* value) { in ValuePrinter() argument
65 const int64_t* val = reinterpret_cast<const int64_t*>(value); in ValuePrinter()
70 string BoxedValue::ValuePrinter<uint64_t>(const void* value) { in ValuePrinter() argument
71 const uint64_t* val = reinterpret_cast<const uint64_t*>(value); in ValuePrinter()
[all …]
/system/bt/common/
Dlru_unittest.cc32 int* value = new int(0); in TEST() local
41 EXPECT_TRUE(cache.Get(1, value)); in TEST()
42 EXPECT_EQ(*value, 10); in TEST()
43 EXPECT_TRUE(cache.Get(2, value)); in TEST()
44 EXPECT_EQ(*value, 20); in TEST()
45 EXPECT_TRUE(cache.Get(3, value)); in TEST()
46 EXPECT_EQ(*value, 30); in TEST()
51 EXPECT_FALSE(cache.Get(1, value)); in TEST()
52 EXPECT_TRUE(cache.Get(4, value)); in TEST()
53 EXPECT_EQ(*value, 40); in TEST()
[all …]
/system/chre/apps/chqts/src/shared/
Dnano_endian_le_test.cc37 uint32_t value; in TEST() local
38 ::memcpy(&value, kLittleEndianRepresentation, sizeof(value)); in TEST()
40 value = nanoapp_testing::littleEndianToHost(value); in TEST()
41 EXPECT_EQ(0, ::memcmp(&value, kLittleEndianRepresentation, sizeof(value))); in TEST()
45 uint32_t value; in TEST() local
46 ::memcpy(&value, kLittleEndianRepresentation, sizeof(value)); in TEST()
48 value = nanoapp_testing::hostToLittleEndian(value); in TEST()
49 EXPECT_EQ(0, ::memcmp(&value, kLittleEndianRepresentation, sizeof(value))); in TEST()
Dnano_endian_be_test.cc39 uint32_t value; in TEST() local
40 ::memcpy(&value, kLittleEndianRepresentation, sizeof(value)); in TEST()
42 value = nanoapp_testing::littleEndianToHost(value); in TEST()
43 EXPECT_EQ(0, ::memcmp(&value, kBigEndianRepresentation, sizeof(value))); in TEST()
47 uint32_t value; in TEST() local
48 ::memcpy(&value, kBigEndianRepresentation, sizeof(value)); in TEST()
50 value = nanoapp_testing::hostToLittleEndian(value); in TEST()
51 EXPECT_EQ(0, ::memcmp(&value, kLittleEndianRepresentation, sizeof(value))); in TEST()
/system/core/init/
Dproperty_type.cpp31 bool CheckType(const std::string& type_string, const std::string& value) { in CheckType() argument
33 if (value.empty()) { in CheckType()
47 return value == "true" || value == "false" || value == "1" || value == "0"; in CheckType()
51 return ParseInt(value, &parsed); in CheckType()
55 if (value.empty() || value.front() == '-') { in CheckType()
58 return ParseUint(value, &parsed); in CheckType()
62 return ParseDouble(value.c_str(), &parsed); in CheckType()
65 auto it = value.begin(); in CheckType()
66 while (it != value.end() && isdigit(*it)) { in CheckType()
69 if (it == value.begin() || it == value.end() || (*it != 'g' && *it != 'k' && *it != 'm')) { in CheckType()
[all …]
/system/core/libunwindstack/
DDwarfMemory.cpp38 bool DwarfMemory::ReadSigned(uint64_t* value) { in ReadSigned() argument
43 *value = static_cast<int64_t>(signed_value); in ReadSigned()
47 bool DwarfMemory::ReadULEB128(uint64_t* value) { in ReadULEB128() argument
58 *value = cur_value; in ReadULEB128()
62 bool DwarfMemory::ReadSLEB128(int64_t* value) { in ReadSLEB128() argument
77 *value = static_cast<int64_t>(cur_value); in ReadSLEB128()
105 bool DwarfMemory::AdjustEncodedValue(uint8_t encoding, uint64_t* value) { in AdjustEncodedValue() argument
118 *value += pc_offset_; in AdjustEncodedValue()
125 *value += text_offset_; in AdjustEncodedValue()
132 *value += data_offset_; in AdjustEncodedValue()
[all …]
/system/teeui/libteeui/src/
Dcbor.cpp29 WriteState writeBytes(WriteState state, uint64_t value, uint8_t size) { in writeBytes() argument
34 *pos++ = getByte(value, 7); in writeBytes()
35 *pos++ = getByte(value, 6); in writeBytes()
36 *pos++ = getByte(value, 5); in writeBytes()
37 *pos++ = getByte(value, 4); in writeBytes()
40 *pos++ = getByte(value, 3); in writeBytes()
41 *pos++ = getByte(value, 2); in writeBytes()
44 *pos++ = getByte(value, 1); in writeBytes()
47 *pos++ = getByte(value, 0); in writeBytes()
57 WriteState writeHeader(WriteState wState, Type type, const uint64_t value) { in writeHeader() argument
[all …]
/system/bt/gd/packet/parser/
Dutil.h63 inline std::string CamelCaseToUnderScore(std::string value) { in CamelCaseToUnderScore() argument
64 if (value[0] < 'A' || value[0] > 'Z') { in CamelCaseToUnderScore()
65 ERROR() << value << " doesn't look like CamelCase"; in CamelCaseToUnderScore()
72 value = std::regex_replace(value, camel_case_regex, "$&_"); in CamelCaseToUnderScore()
75 value.pop_back(); in CamelCaseToUnderScore()
78 …std::transform(value.begin(), value.end(), value.begin(), [](unsigned char c) { return std::tolowe… in CamelCaseToUnderScore()
80 return value; in CamelCaseToUnderScore()
83 inline std::string UnderscoreToCamelCase(std::string value) { in UnderscoreToCamelCase() argument
84 if (value[0] < 'a' || value[0] > 'z') { in UnderscoreToCamelCase()
85 ERROR() << value << " invalid identifier"; in UnderscoreToCamelCase()
[all …]
/system/bt/packet/base/
Dpacket_builder.h35 bool AddPayloadOctets1(const std::shared_ptr<Packet>& pkt, uint8_t value) { in AddPayloadOctets1() argument
36 return AddPayloadOctets(pkt, 1, value); in AddPayloadOctets1()
38 bool AddPayloadOctets2(const std::shared_ptr<Packet>& pkt, uint16_t value) { in AddPayloadOctets2() argument
39 return AddPayloadOctets(pkt, 2, value); in AddPayloadOctets2()
41 bool AddPayloadOctets3(const std::shared_ptr<Packet>& pkt, uint32_t value) { in AddPayloadOctets3() argument
42 return AddPayloadOctets(pkt, 3, value); in AddPayloadOctets3()
44 bool AddPayloadOctets4(const std::shared_ptr<Packet>& pkt, uint32_t value) { in AddPayloadOctets4() argument
45 return AddPayloadOctets(pkt, 4, value); in AddPayloadOctets4()
47 bool AddPayloadOctets6(const std::shared_ptr<Packet>& pkt, uint64_t value) { in AddPayloadOctets6() argument
48 return AddPayloadOctets(pkt, 6, value); in AddPayloadOctets6()
[all …]
/system/bt/osi/test/
Dproperties_test.cc28 char value[PROPERTY_VALUE_MAX] = {0}; in TEST_F() local
29 osi_property_get("very.useful.test", value, "very_useful_value"); in TEST_F()
30 ASSERT_STREQ(value, "very_useful_value"); in TEST_F()
34 char value[PROPERTY_VALUE_MAX] = "nothing_interesting"; in TEST_F() local
35 int ret = osi_property_set("very.useful.set.test", value); in TEST_F()
44 int32_t value = 42; in TEST_F() local
45 int32_t rvalue = osi_property_get_int32("very.useful.test", value); in TEST_F()
46 ASSERT_EQ(rvalue, value); in TEST_F()
50 char value[PROPERTY_VALUE_MAX] = "42"; in TEST_F() local
51 int ret = osi_property_set("very.useful.set.test", value); in TEST_F()
/system/linkerconfig/modules/tests/
Dvariables_test.cc27 auto value = Variables::GetValue("TEST_KEY"); in TEST() local
28 ASSERT_TRUE(value.has_value()); in TEST()
29 ASSERT_EQ("TEST_VALUE", value.value()); in TEST()
39 auto value = Variables::GetValue("debug.linkerconfig.test_prop_key"); in TEST() local
40 ASSERT_TRUE(value.has_value()); in TEST()
41 ASSERT_EQ("TEST_PROP_VALUE", value.value()); in TEST()
46 auto value = Variables::GetValue("INVALID_KEY"); in TEST() local
47 ASSERT_FALSE(value.has_value()); in TEST()
/system/bt/main/shim/
Dconfig.cc46 const std::string& property, int* value) { in GetInt() argument
47 ASSERT(value != nullptr); in GetInt()
51 *value = *ret; in GetInt()
57 const std::string& property, int value) { in SetInt() argument
59 .SetInt(section, property, value); in SetInt()
65 uint64_t* value) { in GetUint64() argument
66 ASSERT(value != nullptr); in GetUint64()
70 *value = *ret; in GetUint64()
77 uint64_t value) { in SetUint64() argument
79 .SetUint64(section, property, value); in SetUint64()
[all …]
/system/core/libcutils/
Dstr_parms.cpp89 static bool remove_pair(void *key, void *value, void *context) in remove_pair() argument
115 free(value); in remove_pair()
160 char *value; in str_parms_create_str() local
170 value = strdup(eq); in str_parms_create_str()
172 value = strdup(""); in str_parms_create_str()
175 value = strdup(""); in str_parms_create_str()
179 old_val = hashmapPut(str_parms->map, key, value); in str_parms_create_str()
180 RELEASE_OWNERSHIP(value); in str_parms_create_str()
207 const char *value) in str_parms_add_str() argument
223 tmp_val = strdup(value); in str_parms_add_str()
[all …]
/system/bt/embdrv/sbc/decoder/include/
Doi_bitstream.h53 INLINE void OI_BITSTREAM_WriteUINT(OI_BITSTREAM* bs, uint16_t value,
78 #define OI_BITSTREAM_READUINT(result, bits, ptr, value, bitPtr) \ argument
84 (result) = (value) << (bitPtr); \
89 (value) = ((value) << 8) | *(ptr)++; \
95 #define OI_BITSTREAM_WRITEUINT(ptr, value, bitPtr, datum, bits) \ argument
98 (value) |= (datum) << (bitPtr); \
102 *(ptr)++ = (uint8_t)((value) >> 24); \
103 (value) <<= 8; \
107 #define OI_BITSTREAM_WRITEFLUSH(ptr, value, bitPtr) \ argument
111 *(ptr)++ = (uint8_t)((value) >> 24); \
[all …]
/system/bt/gd/packet/
Draw_builder.cc47 bool RawBuilder::AddOctets(size_t octets, uint64_t value) { in AddOctets() argument
50 uint64_t v = value; in AddOctets()
73 bool RawBuilder::AddOctets1(uint8_t value) { in AddOctets1() argument
74 return AddOctets(1, value); in AddOctets1()
77 bool RawBuilder::AddOctets2(uint16_t value) { in AddOctets2() argument
78 return AddOctets(2, value); in AddOctets2()
81 bool RawBuilder::AddOctets3(uint32_t value) { in AddOctets3() argument
82 return AddOctets(3, value); in AddOctets3()
85 bool RawBuilder::AddOctets4(uint32_t value) { in AddOctets4() argument
86 return AddOctets(4, value); in AddOctets4()
[all …]
/system/media/audio_utils/tests/
Dvariadic_tests.cpp31 auto value = (expr); \
32 printf("(%s): %s\n", #expr, std::to_string(value).c_str()); \
33 if ((expected) == (expected)) { EXPECT_EQ((expected), (value)); } \
34 EXPECT_EQ((expected) != (expected), (value) != (value)); /* nan check */\
39 auto value = (expr); \
40 printf("(%s): %s\n", #expr, std::to_string(value).c_str()); \
41 TEST_EXPECT_NEAR(ref, value); \
70 EXPECT_FALSE(android::audio_utils::is_variadic<double>::value); in TEST()
74 EXPECT_TRUE(android::audio_utils::is_variadic<tuple_t>::value); in TEST()
75 EXPECT_TRUE(android::audio_utils::is_tuple<tuple_t>::value); in TEST()
[all …]
/system/update_engine/common/
Dprefs_unittest.cc135 bool SetValue(const string& key, const string& value) { in SetValue() argument
137 value.data(), in SetValue()
138 value.length()) == static_cast<int>(value.length()); in SetValue()
176 EXPECT_EQ(prefs_dir_.Append(kAllvalidCharsKey).value(), path.value()); in TEST_F()
204 string value; in TEST_F() local
205 EXPECT_TRUE(prefs_.GetString(kKey, &value)); in TEST_F()
206 EXPECT_EQ(test_data, value); in TEST_F()
210 string value; in TEST_F() local
211 EXPECT_FALSE(prefs_.GetString(",bad", &value)); in TEST_F()
215 string value; in TEST_F() local
[all …]

12345678910>>...40