Heap report sections of the LEDATA output

The Heap Report sections of the LEDATA output provide information for each heap segment in the dump. The detailed heap segment reports include information on the free storage tree in the heap segments, the allocated storage elements, and the cause of heap management data structure problems.

Table 1. Contents of the Heap report sections of LEDATA output
Section Number and Heading Contents
[1] Free Storage Tree Report Within each heap segment, Language Environment keeps track of unallocated storage areas by chaining them together into a tree. Each free area represents a node in the tree. Each node contains a header, which points to its left and right child nodes. The header also contains the length of each child.
The LEDATA HEAP option formats the free storage tree within each heap, and validates all node addresses and lengths within each node. Each node address is validated to ensure that it:
  • Falls on a doubleword boundary
  • Falls within the current heap segment
  • Does not point to itself
  • Does not point to a node that was previously traversed
Each node length is validated to ensure that it:
  • Is a multiple of 8
  • Is not larger than the heap segment length
  • Does not cause the end of the node to fall outside of the current heap segment
  • Does not cause the node to overlap another node
If the formatter finds a problem, then it will place an error message describing the problem directly after the formatted line of the node that failed validation
[2] Heap Segment Map Report The LEDATA HEAP option produces a report that lists all of the storage areas within each heap segment, and identifies the area as either allocated or freed. For each allocated area the contents of the first X'20 'bytes of the area are displayed in order to help identify the reason for the storage allocation.
Each allocated storage element has an 8 byte prefix used by Language Environment to manage the area. The first fullword contains a pointer to the start of the heap segment. The second fullword contains the length of the allocated storage element. The formatter validates this header to ensure that its heap segment pointer is valid. The length is also validated to ensure that it:
  • Is a multiple of 8
  • Is not zero
  • Is not larger than the heap segment length
  • Does not cause the end of the element to fall outside of the current heap segment
  • Does not cause the element to overlap a free storage node
If the heap_free_value of the STORAGE runtime option was specified, then the formatter also checks that the free storage within each free storage element is set to the requested heap_free_value. If a problem is found, then an error message describing the problem is placed after the formatted line of the storage element that failed validation.