| /freebsd-13.1/contrib/llvm-project/compiler-rt/lib/scudo/standalone/ |
| H A D | memtag.h | 34 inline uptr untagPointer(uptr Ptr) { return Ptr & ((1ULL << 56) - 1); } in untagPointer() argument 36 inline uint8_t extractTag(uptr Ptr) { return (Ptr >> 56) & 0xf; } in extractTag() argument 47 (void)Ptr; 52 (void)Ptr; 153 : [Ptr] "r"(Ptr), [ExcludeMask] "r"(ExcludeMask)); in selectRandomTag() 159 DCHECK_EQ(untagPointer(Ptr), Ptr); in addFixedTag() 241 uptr TaggedPtr = Ptr; in loadTag() 272 (void)Ptr; in selectRandomTag() 278 (void)Ptr; in addFixedTag() 290 (void)Ptr; in storeTag() [all …]
|
| H A D | combined.h | 74 Ptr = untagPointer(Ptr); in recycle() 90 Ptr = reinterpret_cast<void *>(reinterpret_cast<uptr>(Ptr) + in allocate() 104 return Ptr; in allocate() 241 return Ptr; in getHeaderTaggedPointer() 460 Ptr = addHeaderTag(Ptr); 470 Ptr = addHeaderTag(Ptr); 534 Ptr = getHeaderTaggedPointer(Ptr); 818 Ptr = getHeaderTaggedPointer(const_cast<void *>(Ptr)); in getUsableSize() 843 Ptr = getHeaderTaggedPointer(const_cast<void *>(Ptr)); in isOwned() 1063 Ptr = untagPointer(const_cast<void *>(Ptr)); in getSize() [all …]
|
| H A D | chunk.h | 90 inline AtomicPackedHeader *getAtomicHeader(void *Ptr) { in getAtomicHeader() argument 97 reinterpret_cast<uptr>(Ptr) - getHeaderSize()); in getConstAtomicHeader() 113 inline void storeHeader(u32 Cookie, void *Ptr, in storeHeader() argument 116 computeHeaderChecksum(Cookie, Ptr, NewUnpackedHeader); in storeHeader() 118 atomic_store_relaxed(getAtomicHeader(Ptr), NewPackedHeader); in storeHeader() 121 inline void loadHeader(u32 Cookie, const void *Ptr, in loadHeader() argument 127 reportHeaderCorruption(const_cast<void *>(Ptr)); in loadHeader() 130 inline void compareExchangeHeader(u32 Cookie, void *Ptr, in compareExchangeHeader() argument 134 computeHeaderChecksum(Cookie, Ptr, NewUnpackedHeader); in compareExchangeHeader() 140 reportHeaderRace(Ptr); in compareExchangeHeader() [all …]
|
| H A D | report.cpp | 65 void NORETURN reportHeaderCorruption(void *Ptr) { in reportHeaderCorruption() argument 67 Report.append("corrupted chunk header at address %p\n", Ptr); in reportHeaderCorruption() 73 void NORETURN reportHeaderRace(void *Ptr) { in reportHeaderRace() argument 75 Report.append("race on chunk header at address %p\n", Ptr); in reportHeaderRace() 124 void NORETURN reportInvalidChunkState(AllocatorAction Action, void *Ptr) { in reportInvalidChunkState() argument 127 stringifyAction(Action), Ptr); in reportInvalidChunkState() 130 void NORETURN reportMisalignedPointer(AllocatorAction Action, void *Ptr) { in reportMisalignedPointer() argument 133 stringifyAction(Action), Ptr); in reportMisalignedPointer() 138 void NORETURN reportDeallocTypeMismatch(AllocatorAction Action, void *Ptr, in reportDeallocTypeMismatch() argument 142 stringifyAction(Action), Ptr, TypeA, TypeB); in reportDeallocTypeMismatch() [all …]
|
| /freebsd-13.1/contrib/llvm-project/llvm/lib/Support/ |
| H A D | Twine.cpp | 63 Ptr.twine->print(OS); in printOneChild() 66 OS << Ptr.cString; in printOneChild() 72 OS << StringRef(Ptr.ptrAndLength.ptr, Ptr.ptrAndLength.length); in printOneChild() 78 OS << Ptr.character; in printOneChild() 81 OS << Ptr.decUI; in printOneChild() 84 OS << Ptr.decI; in printOneChild() 87 OS << *Ptr.decUL; in printOneChild() 90 OS << *Ptr.decL; in printOneChild() 93 OS << *Ptr.decULL; in printOneChild() 96 OS << *Ptr.decLL; in printOneChild() [all …]
|
| H A D | FormattedStream.cpp | 61 PartialUTF8Char.append(StringRef(Ptr, Size)); in UpdatePosition() 70 Ptr += BytesFromBuffer; in UpdatePosition() 77 for (const char *End = Ptr + Size; Ptr < End; Ptr += NumBytes) { in UpdatePosition() 78 NumBytes = getNumBytesForUTF8(*Ptr); in UpdatePosition() 85 if ((unsigned)(End - Ptr) < NumBytes) { in UpdatePosition() 86 PartialUTF8Char = StringRef(Ptr, End - Ptr); in UpdatePosition() 100 if (Ptr <= Scanned && Scanned <= Ptr + Size) in ComputePosition() 105 UpdatePosition(Ptr, Size); in ComputePosition() 108 Scanned = Ptr + Size; in ComputePosition() 126 ComputePosition(Ptr, Size); in write_impl() [all …]
|
| /freebsd-13.1/contrib/llvm-project/clang/lib/AST/Interp/ |
| H A D | Interp.cpp | 103 if (Ptr.isInitialized()) in CheckInitialized() 114 if (Ptr.isActive()) in CheckActive() 166 if (!Ptr.isStatic()) in CheckGlobal() 182 if (!Ptr.isExtern()) in CheckExtern() 205 if (Ptr.isZero()) { in CheckLive() 207 if (Ptr.isField()) in CheckLive() 215 if (!Ptr.isLive()) { in CheckLive() 233 if (!Ptr.isZero()) in CheckNull() 242 if (!Ptr.isOnePastEnd()) in CheckRange() 260 if (!Ptr.isConst()) { in CheckConst() [all …]
|
| H A D | Source.h | 27 CodePtr() : Ptr(nullptr) {} in CodePtr() 30 Ptr += Offset; 35 assert(Ptr != nullptr && RHS.Ptr != nullptr && "Invalid code pointer"); 36 return Ptr - RHS.Ptr; 41 return CodePtr(Ptr - RHS); 44 bool operator!=(const CodePtr &RHS) const { return Ptr != RHS.Ptr; } 49 Ptr += sizeof(T); in read() 55 CodePtr(const char *Ptr) : Ptr(Ptr) {} in CodePtr() argument 60 ReadHelper(const char *Ptr) { in ReadHelper() argument 67 ReadHelper(const char *Ptr) { in ReadHelper() argument [all …]
|
| H A D | Interp.h | 547 Ptr.deactivate(); in GetPtrActiveField() 586 Pointer Base = Ptr; in VirtBaseHelper() 619 if (!CheckLoad(S, OpPC, Ptr)) in Load() 640 Ptr.deref<T>() = Value; in Store() 650 Ptr.deref<T>() = Value; in StorePop() 663 Ptr.deref<T>() = Value; in StoreBitField() 677 Ptr.deref<T>() = Value; in StoreBitFieldPop() 688 Ptr.initialize(); in InitPop() 699 Ptr.initialize(); in InitElem() 710 Ptr.initialize(); in InitElemPop() [all …]
|
| /freebsd-13.1/contrib/llvm-project/compiler-rt/lib/scudo/ |
| H A D | scudo_allocator.cpp | 182 void Recycle(void *Ptr) { in Recycle() 292 if (UNLIKELY(!Ptr)) in isValidPointer() 319 return Ptr; in allocate() 401 return Ptr; in allocate() 457 if (UNLIKELY(!Ptr)) in deallocate() 547 if (UNLIKELY(!Ptr)) in getUsableSize() 716 if (!Ptr) in scudoRealloc() 754 if (UNLIKELY(!Ptr)) in scudoPosixMemalign() 756 *MemPtr = Ptr; in scudoPosixMemalign() 811 (void)Ptr; in SANITIZER_INTERFACE_WEAK_DEF() [all …]
|
| /freebsd-13.1/contrib/llvm-project/compiler-rt/lib/gwp_asan/platform_specific/ |
| H A D | guarded_pool_allocator_posix.cpp | 47 void *Ptr = mmap(nullptr, Size, PROT_READ | PROT_WRITE, in map() local 50 MaybeSetMappingName(Ptr, Size, Name); in map() 51 return Ptr; in map() 57 Check(munmap(Ptr, Size) == 0, in unmap() 63 void *Ptr = in reserveGuardedPool() local 66 MaybeSetMappingName(Ptr, Size, kGwpAsanGuardPageName); in reserveGuardedPool() 67 return Ptr; in reserveGuardedPool() 78 Check(mprotect(Ptr, Size, PROT_READ | PROT_WRITE) == 0, in allocateInGuardedPool() 80 MaybeSetMappingName(Ptr, Size, kGwpAsanAliveSlotName); in allocateInGuardedPool() 83 void GuardedPoolAllocator::deallocateInGuardedPool(void *Ptr, in deallocateInGuardedPool() argument [all …]
|
| /freebsd-13.1/contrib/llvm-project/clang/include/clang/Sema/ |
| H A D | IdentifierResolver.h | 83 uintptr_t Ptr = 0; variable 88 Ptr = reinterpret_cast<uintptr_t>(D); in iterator() 89 assert((Ptr & 0x1) == 0 && "Invalid Ptr!"); in iterator() 95 Ptr = reinterpret_cast<uintptr_t>(I) | 0x1; in iterator() 98 bool isIterator() const { return (Ptr & 0x1); } in isIterator() 102 return reinterpret_cast<BaseIter>(Ptr & ~0x1); in getIterator() 114 return reinterpret_cast<NamedDecl*>(Ptr); 118 return Ptr == RHS.Ptr; 121 return Ptr != RHS.Ptr; 127 Ptr = 0; [all …]
|
| /freebsd-13.1/contrib/llvm-project/clang/lib/Sema/ |
| H A D | IdentifierResolver.cpp | 151 if (!Ptr) { in AddDecl() 158 if (isDeclPtr(Ptr)) { in AddDecl() 176 if (!Ptr) { in InsertDeclAfter() 181 if (isDeclPtr(Ptr)) { in InsertDeclAfter() 219 if (isDeclPtr(Ptr)) { in RemoveDecl() 235 if (!Ptr) return end(); in begin() 237 if (isDeclPtr(Ptr)) in begin() 308 if (!Ptr) { in tryAddTopLevelDecl() 315 if (isDeclPtr(Ptr)) { in tryAddTopLevelDecl() 345 IDI = toIdDeclInfo(Ptr); in tryAddTopLevelDecl() [all …]
|
| /freebsd-13.1/contrib/llvm-project/lld/MachO/ |
| H A D | UnwindInfoSection.cpp | 106 template <class Ptr> 143 template <class Ptr> 156 template <class Ptr> 244 template <class Ptr> 245 constexpr Ptr TombstoneValue = std::numeric_limits<Ptr>::max(); 251 template <class Ptr> 286 template <class Ptr> 317 template <class Ptr> 329 Ptr ptr = d->getVA(); in addEntriesForFunctionsWithoutUnwindInfo() 372 template <class Ptr> void UnwindInfoSectionImpl<Ptr>::finalize() { in finalize() [all …]
|
| /freebsd-13.1/contrib/llvm-project/llvm/include/llvm/Support/ |
| H A D | SMLoc.h | 24 const char *Ptr = nullptr; variable 29 bool isValid() const { return Ptr != nullptr; } in isValid() 31 bool operator==(const SMLoc &RHS) const { return RHS.Ptr == Ptr; } 32 bool operator!=(const SMLoc &RHS) const { return RHS.Ptr != Ptr; } 34 const char *getPointer() const { return Ptr; } in getPointer() 36 static SMLoc getFromPointer(const char *Ptr) { in getFromPointer() argument 38 L.Ptr = Ptr; in getFromPointer()
|
| H A D | ManagedStatic.h | 29 static void call(void *Ptr) { delete (T *)Ptr; } in call() 32 static void call(void *Ptr) { delete[](T *)Ptr; } 52 mutable std::atomic<void *> Ptr{}; 58 mutable std::atomic<void *> Ptr; 71 bool isConstructed() const { return Ptr != nullptr; } 87 void *Tmp = Ptr.load(std::memory_order_acquire); 91 return *static_cast<C *>(Ptr.load(std::memory_order_relaxed)); 97 void *Tmp = Ptr.load(std::memory_order_acquire); 101 return *static_cast<C *>(Ptr.load(std::memory_order_relaxed)); 109 return static_cast<C *>(Ptr.exchange(nullptr));
|
| H A D | ArrayRecycler.h | 56 void push(unsigned Idx, T *Ptr) { in push() argument 57 assert(Ptr && "Cannot recycle NULL pointer"); in push() 58 FreeList *Entry = reinterpret_cast<FreeList*>(Ptr); in push() 63 __asan_poison_memory_region(Ptr, Capacity::get(Idx).getSize()); in push() 106 while (T *Ptr = pop(Bucket.size() - 1)) in clear() local 107 Allocator.Deallocate(Ptr); in clear() 127 if (T *Ptr = pop(Cap.getBucket())) in allocate() local 128 return Ptr; in allocate() 137 void deallocate(Capacity Cap, T *Ptr) { in deallocate() argument 138 push(Cap.getBucket(), Ptr); in deallocate()
|
| /freebsd-13.1/contrib/llvm-project/llvm/tools/llvm-objcopy/COFF/ |
| H A D | Writer.cpp | 249 Ptr += Obj.DosStub.size(); in writeHeaders() 251 Ptr += sizeof(PEMagic); in writeHeaders() 278 Ptr += sizeof(BigObjHeader); in writeHeaders() 291 Ptr += sizeof(PeHeader); in writeHeaders() 295 Ptr += sizeof(DD); in writeHeaders() 300 Ptr += sizeof(S.Header); in writeHeaders() 326 Ptr += sizeof(R); in writeSections() 330 Ptr += sizeof(R.Reloc); in writeSections() 342 Ptr += sizeof(SymbolTy); in writeSymbolStringTables() 363 StrTabBuilder.write(Ptr); in writeSymbolStringTables() [all …]
|
| /freebsd-13.1/contrib/llvm-project/compiler-rt/lib/gwp_asan/ |
| H A D | common.cpp | 81 bool AllocatorState::isGuardPage(uintptr_t Ptr) const { in isGuardPage() 82 assert(pointerIsMine(reinterpret_cast<void *>(Ptr))); in isGuardPage() 89 size_t ByteOffsetFromPoolStart = Ptr - State->GuardedPagePool; in addrToSlot() 94 size_t AllocatorState::getNearestSlot(uintptr_t Ptr) const { in getNearestSlot() 95 if (Ptr <= GuardedPagePool + PageSize) in getNearestSlot() 97 if (Ptr > GuardedPagePoolEnd - PageSize) in getNearestSlot() 100 if (!isGuardPage(Ptr)) in getNearestSlot() 101 return addrToSlot(this, Ptr); in getNearestSlot() 103 if (Ptr % PageSize <= PageSize / 2) in getNearestSlot() 104 return addrToSlot(this, Ptr - PageSize); // Round down. in getNearestSlot() [all …]
|
| H A D | guarded_pool_allocator.cpp | 34 return Ptr & ~(PageSize - 1); in getPageAddr() 169 if ((Ptr & (Alignment - 1)) == 0) in alignUp() 170 return Ptr; in alignUp() 172 Ptr += Alignment - (Ptr & (Alignment - 1)); in alignUp() 173 return Ptr; in alignUp() 179 if ((Ptr & (Alignment - 1)) == 0) in alignDown() 180 return Ptr; in alignDown() 182 Ptr -= Ptr & (Alignment - 1); in alignDown() 183 return Ptr; in alignDown() 315 assert(pointerIsMine(Ptr)); in getSize() [all …]
|
| /freebsd-13.1/contrib/llvm-project/llvm/include/llvm/ADT/ |
| H A D | SmallPtrSet.h | 132 if (Value == Ptr) in insert_imp() 140 *LastTombstone = Ptr; in insert_imp() 148 SmallArray[NumNonEmpty++] = Ptr; in insert_imp() 154 return insert_imp_big(Ptr); in insert_imp() 161 bool erase_imp(const void * Ptr) { in erase_imp() argument 162 const void *const *P = find_imp(Ptr); in erase_imp() 181 if (*APtr == Ptr) in find_imp() 187 auto *Bucket = FindBucketFor(Ptr); in find_imp() 188 if (*Bucket == Ptr) in find_imp() 373 return insert(Ptr).first; [all …]
|
| /freebsd-13.1/sys/contrib/dev/acpica/os_specific/service_layers/ |
| H A D | osgendbg.c | 191 char *Ptr = BatchBuffer; in AcpiDbRunRemoteDebugger() local 192 char *Cmd = Ptr; in AcpiDbRunRemoteDebugger() 199 if (*Ptr) in AcpiDbRunRemoteDebugger() 201 while (*Ptr) in AcpiDbRunRemoteDebugger() 203 if (*Ptr == ',') in AcpiDbRunRemoteDebugger() 206 *Ptr = ' '; in AcpiDbRunRemoteDebugger() 208 else if (*Ptr == ';') in AcpiDbRunRemoteDebugger() 210 *Ptr = '\0'; in AcpiDbRunRemoteDebugger() 214 Ptr++; in AcpiDbRunRemoteDebugger() 218 Ptr++; in AcpiDbRunRemoteDebugger() [all …]
|
| /freebsd-13.1/contrib/llvm-project/clang/include/clang/AST/ |
| H A D | ExternalASTSource.h | 329 mutable uint64_t Ptr = 0; member 333 explicit LazyOffsetPtr(T *Ptr) : Ptr(reinterpret_cast<uint64_t>(Ptr)) {} in LazyOffsetPtr() 338 Ptr = 0; in LazyOffsetPtr() 341 LazyOffsetPtr &operator=(T *Ptr) { 342 this->Ptr = reinterpret_cast<uint64_t>(Ptr); 349 Ptr = 0; 351 Ptr = (Offset << 1) | 0x01; 364 bool isValid() const { return Ptr != 0; } in isValid() 378 Ptr = reinterpret_cast<uint64_t>((Source->*Get)(Ptr >> 1)); in get() 380 return reinterpret_cast<T*>(Ptr); in get() [all …]
|
| H A D | DependentDiagnostic.h | 128 explicit ddiag_iterator(DependentDiagnostic *Ptr) : Ptr(Ptr) {} in ddiag_iterator() argument 136 reference operator*() const { return Ptr; } 139 assert(Ptr && "attempt to increment past end of diag list"); 140 Ptr = Ptr->NextDiagnostic; 151 return Ptr == Other.Ptr; 155 return Ptr != Other.Ptr; 172 DependentDiagnostic *Ptr = nullptr;
|
| /freebsd-13.1/contrib/llvm-project/llvm/lib/Target/AMDGPU/ |
| H A D | AMDGPUInstrInfo.cpp | 32 const Value *Ptr = MMO->getValue(); in isUniformMMO() local 37 if (!Ptr || isa<UndefValue>(Ptr) || in isUniformMMO() 38 isa<Constant>(Ptr) || isa<GlobalValue>(Ptr)) in isUniformMMO() 44 if (const Argument *Arg = dyn_cast<Argument>(Ptr)) in isUniformMMO() 47 const Instruction *I = dyn_cast<Instruction>(Ptr); in isUniformMMO()
|