Home
last modified time | relevance | path

Searched refs:uintptr_t (Results 1 – 25 of 98) sorted by relevance

1234

/bionic/linker/
Dlinker_cfi.h47 uint16_t* MemToShadow(uintptr_t x) { in MemToShadow()
52 void AddConstant(uintptr_t begin, uintptr_t end, uint16_t v);
55 void AddUnchecked(uintptr_t begin, uintptr_t end);
58 void AddInvalid(uintptr_t begin, uintptr_t end);
61 void Add(uintptr_t begin, uintptr_t end, uintptr_t cfi_check);
67 uintptr_t MapShadow();
79 bool NotifyLibDl(soinfo *solist, uintptr_t p);
82 uintptr_t *shadow_start;
Dlinker_cfi.cpp53 aligned_start = reinterpret_cast<char*>(PAGE_START(reinterpret_cast<uintptr_t>(shadow_start))); in ShadowWrite()
54 aligned_end = reinterpret_cast<char*>(PAGE_END(reinterpret_cast<uintptr_t>(shadow_end))); in ShadowWrite()
84 void CFIShadowWriter::AddConstant(uintptr_t begin, uintptr_t end, uint16_t v) { in AddConstant()
92 void CFIShadowWriter::AddUnchecked(uintptr_t begin, uintptr_t end) { in AddUnchecked()
96 void CFIShadowWriter::AddInvalid(uintptr_t begin, uintptr_t end) { in AddInvalid()
100 void CFIShadowWriter::Add(uintptr_t begin, uintptr_t end, uintptr_t cfi_check) { in Add()
143 static uintptr_t soinfo_find_symbol(soinfo* si, const char* s) { in soinfo_find_symbol()
152 uintptr_t soinfo_find_cfi_check(soinfo* si) { in soinfo_find_cfi_check()
156 uintptr_t CFIShadowWriter::MapShadow() { in MapShadow()
160 return reinterpret_cast<uintptr_t>(p); in MapShadow()
[all …]
Dlinker_block_allocator_test.cpp68 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
70 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
88 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
90 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
101 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
103 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
/bionic/libc/private/
DCFIShadow.h55 static constexpr uintptr_t kShadowGranularity = kLibraryAlignmentBits;
56 static constexpr uintptr_t kCfiCheckGranularity = 12;
59 static constexpr uintptr_t kShadowAlign = 1UL << kShadowGranularity;
62 static constexpr uintptr_t kCfiCheckAlign = 1UL << kCfiCheckGranularity; // 4K
65 static constexpr uintptr_t kMaxTargetAddr = 0xffffffffffff;
67 static constexpr uintptr_t kMaxTargetAddr = 0xffffffff;
71 static constexpr uintptr_t kShadowSize =
75 static constexpr uintptr_t MemToShadowOffset(uintptr_t x) { in MemToShadowOffset()
Dbionic_macros.h34 static constexpr uintptr_t align_down(uintptr_t p, size_t align) { in align_down()
38 static constexpr uintptr_t align_up(uintptr_t p, size_t align) { in align_up()
44 return reinterpret_cast<T*>(align_down(reinterpret_cast<uintptr_t>(p), align)); in align_down()
49 return reinterpret_cast<T*>(align_up(reinterpret_cast<uintptr_t>(p), align)); in align_up()
DKernelArgumentBlock.h33 uintptr_t* args = reinterpret_cast<uintptr_t*>(raw_args); in KernelArgumentBlock()
/bionic/libc/malloc_debug/
DMapData.h40 …MapEntry(uintptr_t start, uintptr_t end, uintptr_t offset, const char* name, size_t name_len, int … in MapEntry()
43 explicit MapEntry(uintptr_t pc) : start(pc), end(pc) {} in MapEntry()
45 uintptr_t start;
46 uintptr_t end;
47 uintptr_t offset;
48 uintptr_t load_bias;
49 uintptr_t elf_start_offset = 0;
66 const MapEntry* find(uintptr_t pc, uintptr_t* rel_pc = nullptr);
DDebugData.h54 uintptr_t value = reinterpret_cast<uintptr_t>(header); in GetPointer()
59 uintptr_t value = reinterpret_cast<uintptr_t>(pointer); in GetHeader()
64 uintptr_t value = reinterpret_cast<uintptr_t>(header); in GetFrontGuard()
69 uintptr_t value = reinterpret_cast<uintptr_t>(GetPointer(header)); in GetRearGuard()
Dbacktrace.h38 size_t backtrace_get(uintptr_t* frames, size_t frame_count);
39 void backtrace_log(const uintptr_t* frames, size_t frame_count);
40 std::string backtrace_string(const uintptr_t* frames, size_t frame_count);
Dbacktrace.cpp59 uintptr_t ip = _Unwind_GetIP(context); in find_current_map()
75 uintptr_t* frames;
79 stack_crawl_state_t(uintptr_t* frames, size_t frame_count) in stack_crawl_state_t()
86 uintptr_t ip = _Unwind_GetIP(context); in trace_function()
129 size_t backtrace_get(uintptr_t* frames, size_t frame_count) { in backtrace_get()
135 std::string backtrace_string(const uintptr_t* frames, size_t frame_count) { in backtrace_string()
139 uintptr_t offset = 0; in backtrace_string()
144 offset = reinterpret_cast<uintptr_t>(info.dli_saddr); in backtrace_string()
150 uintptr_t rel_pc = offset; in backtrace_string()
181 void backtrace_log(const uintptr_t* frames, size_t frame_count) { in backtrace_log()
DMapData.cpp45 uintptr_t start; in parse_line()
46 uintptr_t end; in parse_line()
47 uintptr_t offset; in parse_line()
81 static inline bool get_val(MapEntry* entry, uintptr_t addr, T* store) { in get_val()
94 uintptr_t addr = entry->start; in valid_elf()
95 uintptr_t end; in valid_elf()
105 uintptr_t addr = entry->start; in read_loadbias()
177 const MapEntry* MapData::find(uintptr_t pc, uintptr_t* rel_pc) { in find()
DPointerData.h54 uintptr_t* frames;
84 std::vector<uintptr_t> frames;
102 uintptr_t pointer;
107 uintptr_t pointer;
143 typedef std::unordered_map<uintptr_t, PointerInfoType>::iterator iterator;
160 static size_t GetFrames(const void* pointer, uintptr_t* frames, size_t max_frames);
165 static std::string GetHashString(uintptr_t* frames, size_t num_frames);
179 static std::unordered_map<uintptr_t, PointerInfoType> pointers_;
/bionic/libdl/
Dlibdl_cfi.cpp28 uintptr_t v;
35 extern "C" uintptr_t* __cfi_init(uintptr_t shadow_base) { in __cfi_init()
47 uintptr_t addr = reinterpret_cast<uintptr_t>(p); in shadow_load()
48 uintptr_t ofs = CFIShadow::MemToShadowOffset(addr); in shadow_load()
53 static uintptr_t cfi_check_addr(uint16_t v, void* Ptr) { in cfi_check_addr()
54 uintptr_t addr = reinterpret_cast<uintptr_t>(Ptr); in cfi_check_addr()
58 uintptr_t aligned_addr = align_down(addr, CFIShadow::kShadowAlign) + CFIShadow::kShadowAlign; in cfi_check_addr()
59 uintptr_t p = aligned_addr - (static_cast<uintptr_t>(v - CFIShadow::kRegularShadowMin) in cfi_check_addr()
/bionic/tests/
Dbionic_allocator_test.cpp111 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(reallocated_ptr) % 16); in TEST()
123 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(reallocated_ptr) % 16); in TEST()
142 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
144 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
146 ASSERT_EQ(reinterpret_cast<uintptr_t>(ptr1)+16, reinterpret_cast<uintptr_t>(ptr2)); in TEST()
163 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
165 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
168 reinterpret_cast<uintptr_t>(ptr1)/kPageSize != reinterpret_cast<uintptr_t>(ptr2)/kPageSize); in TEST()
182 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr1) % 16); in TEST()
184 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr2) % 16); in TEST()
[all …]
Dmalloc_iterate_test.cpp33 extern "C" int malloc_iterate(uintptr_t base, size_t size, void (*callback)(uintptr_t base,
65 static void SavePointers(uintptr_t base, size_t size, void* data) { in SavePointers()
70 uintptr_t end; in SavePointers()
77 uintptr_t ptr = reinterpret_cast<uintptr_t>(test_data->allocs[i].ptr); in SavePointers()
81 uintptr_t max_size = end - ptr; in SavePointers()
Dlink_test.cpp191 static uintptr_t read_exidx_func(uintptr_t* entry) { in read_exidx_func()
197 return reinterpret_cast<uintptr_t>(entry) + offset; in read_exidx_func()
206 uintptr_t one; in TEST()
207 uintptr_t two; in TEST()
215 uintptr_t func = reinterpret_cast<uintptr_t>(read_exidx_func); in TEST()
221 uintptr_t exidx_func = read_exidx_func(&entries[i].one); in TEST()
/bionic/libc/bionic/
Dbrk.cpp61 uintptr_t old_brk = reinterpret_cast<uintptr_t>(__bionic_brk); in sbrk()
62 if ((increment > 0 && static_cast<uintptr_t>(increment) > (UINTPTR_MAX - old_brk)) || in sbrk()
63 (increment < 0 && static_cast<uintptr_t>(-increment) > old_brk)) { in sbrk()
Dscudo_wrapper.cpp51 int scudo_iterate(uintptr_t, size_t, void (*)(uintptr_t, size_t, void*), void*) { in scudo_iterate() argument
Dpthread_key.cpp57 static inline bool SeqOfKeyInUse(uintptr_t seq) { in SeqOfKeyInUse()
85 uintptr_t seq = atomic_load_explicit(&key_map[i].seq, memory_order_relaxed); in pthread_key_clean_all()
126 uintptr_t seq = atomic_load_explicit(&key_map[i].seq, memory_order_relaxed); in pthread_key_create()
129 atomic_store(&key_map[i].key_destructor, reinterpret_cast<uintptr_t>(key_destructor)); in pthread_key_create()
149 uintptr_t seq = atomic_load_explicit(&key_map[key].seq, memory_order_relaxed); in pthread_key_delete()
164 uintptr_t seq = atomic_load_explicit(&key_map[key].seq, memory_order_relaxed); in pthread_getspecific()
183 uintptr_t seq = atomic_load_explicit(&key_map[key].seq, memory_order_relaxed); in pthread_setspecific()
Djemalloc.h32 int je_iterate(uintptr_t, size_t, void (*)(uintptr_t, size_t, void*), void*);
Dscudo.h55 int scudo_iterate(uintptr_t, size_t, void (*)(uintptr_t, size_t, void*), void*);
/bionic/libc/malloc_debug/tests/
Dbacktrace_fake.cpp29 static std::deque<std::vector<uintptr_t>> g_fake_backtrace;
35 void backtrace_fake_add(const std::vector<uintptr_t>& ips) { in backtrace_fake_add()
45 size_t backtrace_get(uintptr_t* frames, size_t frame_num) { in backtrace_get()
52 memcpy(frames, g_fake_backtrace[0].data(), sizeof(uintptr_t) * total_frames); in backtrace_get()
57 void backtrace_log(const uintptr_t* frames, size_t frame_count) { in backtrace_log()
73 bool Unwind(std::vector<uintptr_t>* frames, std::vector<unwindstack::LocalFrameData>* info, size_t)… in Unwind()
/bionic/benchmarks/tests/
Dbenchmark_test.cpp24 uintptr_t aligned_ptr = reinterpret_cast<uintptr_t>(GetAlignedMemory(buf.data(), alignment, in TEST()
35 uintptr_t aligned_ptr = reinterpret_cast<uintptr_t>(GetAlignedPtr(&buf, alignment, 100)); in TEST()
/bionic/tests/libs/
Ddlopen_testlib_ifunc_variable_impl.cpp22 static uintptr_t g_flag = 0;
25 g_flag = reinterpret_cast<uintptr_t>(dlsym(RTLD_DEFAULT, "dlsym")); in init_flag()
Ddlopen_testlib_ifunc.cpp22 static uintptr_t g_flag = 0;
25 g_flag = reinterpret_cast<uintptr_t>(dlsym(RTLD_DEFAULT, "dlsym")); in init_flag()

1234