Lines Matching refs:uptr

29 ALWAYS_INLINE void SetShadow(uptr ptr, uptr size, uptr class_id, u64 magic) {  in SetShadow()
33 for (uptr i = 0; i < (((uptr)1) << class_id); i++) { in SetShadow()
44 FakeStack *FakeStack::Create(uptr stack_size_log) { in Create()
45 static uptr kMinStackSizeLog = 16; in Create()
46 static uptr kMaxStackSizeLog = FIRST_32_SECOND_64(24, 28); in Create()
51 uptr size = RequiredSize(stack_size_log); in Create()
70 for (uptr class_id = 0; class_id < kNumberOfSizeClasses; class_id++) in Destroy()
75 uptr size = RequiredSize(stack_size_log_); in Destroy()
76 FlushUnneededASanShadowMemory(reinterpret_cast<uptr>(this), size); in Destroy()
81 PoisonShadow(reinterpret_cast<uptr>(this), RequiredSize(stack_size_log()), in PoisonAll()
88 FakeFrame *FakeStack::Allocate(uptr stack_size_log, uptr class_id, in Allocate()
89 uptr real_stack) { in Allocate()
93 uptr &hint_position = hint_position_[class_id]; in Allocate()
97 uptr pos = ModuloNumberOfFrames(stack_size_log, class_id, hint_position++); in Allocate()
110 *SavedFlagPtr(reinterpret_cast<uptr>(res), class_id) = &flags[pos]; in Allocate()
116 uptr FakeStack::AddrIsInFakeStack(uptr ptr, uptr *frame_beg, uptr *frame_end) { in AddrIsInFakeStack()
117 uptr stack_size_log = this->stack_size_log(); in AddrIsInFakeStack()
118 uptr beg = reinterpret_cast<uptr>(GetFrame(stack_size_log, 0, 0)); in AddrIsInFakeStack()
119 uptr end = reinterpret_cast<uptr>(this) + RequiredSize(stack_size_log); in AddrIsInFakeStack()
121 uptr class_id = (ptr - beg) >> stack_size_log; in AddrIsInFakeStack()
122 uptr base = beg + (class_id << stack_size_log); in AddrIsInFakeStack()
124 CHECK_LT(ptr, base + (((uptr)1) << stack_size_log)); in AddrIsInFakeStack()
125 uptr pos = (ptr - base) >> (kMinStackFrameSizeLog + class_id); in AddrIsInFakeStack()
126 uptr res = base + pos * BytesInSizeClass(class_id); in AddrIsInFakeStack()
148 NOINLINE void FakeStack::GC(uptr real_stack) { in GC()
157 for (uptr class_id = 0; class_id < kNumberOfSizeClasses; class_id++) { in GC()
159 for (uptr i = 0, n = NumberOfFrames(stack_size_log(), class_id); i < n; in GC()
168 SetShadow(reinterpret_cast<uptr>(ff), BytesInSizeClass(class_id), in GC()
177 for (uptr class_id = 0; class_id < kNumberOfSizeClasses; class_id++) { in ForEachFakeFrame()
179 for (uptr i = 0, n = NumberOfFrames(stack_size_log(), class_id); i < n; in ForEachFakeFrame()
184 uptr begin = reinterpret_cast<uptr>(ff); in ForEachFakeFrame()
224 static ALWAYS_INLINE uptr OnMalloc(uptr class_id, uptr size) { in OnMalloc()
232 uptr ptr = reinterpret_cast<uptr>(ff); in OnMalloc()
237 static ALWAYS_INLINE uptr OnMallocAlways(uptr class_id, uptr size) { in OnMallocAlways()
245 uptr ptr = reinterpret_cast<uptr>(ff); in OnMallocAlways()
250 static ALWAYS_INLINE void OnFree(uptr ptr, uptr class_id, uptr size) { in OnFree()
260 extern "C" SANITIZER_INTERFACE_ATTRIBUTE uptr \
261 __asan_stack_malloc_##class_id(uptr size) { \
264 extern "C" SANITIZER_INTERFACE_ATTRIBUTE uptr \
265 __asan_stack_malloc_always_##class_id(uptr size) { \
269 uptr ptr, uptr size) { \
297 uptr frame_beg, frame_end; in __asan_addr_is_in_fake_stack()
299 reinterpret_cast<uptr>(addr), &frame_beg, &frame_end)); in __asan_addr_is_in_fake_stack()
309 void __asan_alloca_poison(uptr addr, uptr size) { in __asan_alloca_poison()
310 uptr LeftRedzoneAddr = addr - kAllocaRedzoneSize; in __asan_alloca_poison()
311 uptr PartialRzAddr = addr + size; in __asan_alloca_poison()
312 uptr RightRzAddr = (PartialRzAddr + kAllocaRedzoneMask) & ~kAllocaRedzoneMask; in __asan_alloca_poison()
313 uptr PartialRzAligned = PartialRzAddr & ~(ASAN_SHADOW_GRANULARITY - 1); in __asan_alloca_poison()
322 void __asan_allocas_unpoison(uptr top, uptr bottom) { in __asan_allocas_unpoison()