Lines Matching defs:heap

183     // Measure the number of heap ring buffer entries that would have matched
192 // Measure the number of heap ring buffer entries that would have matched
486 heap(CopyHeapChunk()),
503 } heap;
516 ArrayRef<HeapAllocation> heap;
555 const HeapChunk heap;
658 // Scan all threads' ring buffers to find if it's a heap-use-after-free.
682 // Check if this looks like a heap buffer overflow by scanning
710 result.heap.is_allocated = true;
711 result.heap.begin = chunk.Beg();
712 result.heap.end = chunk.End();
713 result.heap.thread_id = chunk.GetAllocThreadId();
714 result.heap.stack_id = chunk.GetAllocStackId();
721 if (candidate.heap.is_allocated) {
724 if (candidate.heap.begin <= untagged_addr &&
725 untagged_addr < candidate.heap.end) {
726 offset = untagged_addr - candidate.heap.begin;
729 offset = untagged_addr - candidate.heap.end;
732 offset = candidate.heap.begin - untagged_addr;
736 Printf("\nCause: heap-buffer-overflow\n");
741 candidate.heap.end - candidate.heap.begin, candidate.heap.begin,
742 candidate.heap.end);
744 Printf("allocated by thread T%u here:\n", candidate.heap.thread_id);
746 GetStackTraceFromId(candidate.heap.stack_id).Print();
800 // Print some very basic information about the address, if it's a heap.
801 if (heap.begin) {
803 "%s[%p,%p) is a %s %s heap chunk; "
805 d.Location(), heap.begin, heap.begin + heap.size,
806 heap.from_small_heap ? "small" : "large",
807 heap.is_allocated ? "allocated" : "unallocated", heap.size,
808 untagged_addr - heap.begin, d.Default());
819 // know it cannot be a heap / global overflow.
838 for (const auto &ha : allocations.heap) {
858 // Print a developer note: the index of this heap object
969 Report("ERROR: %s: %s; heap object [%p,%p) of size %zd\n", SanitizerToolName,
979 if (heap.begin) {
983 GetStackTraceFromId(heap.stack_id).Print();
1003 "after a heap object, but within the %zd-byte granule, e.g.\n"
1035 // TODO: when possible, try to print heap-use-after-free, etc.