主权项 |
1. A computer program product comprising a machine-readable medium storing instructions that, when executed by at least one programmable processor, cause the at least one programmable processor to perform operations comprising:
creating an allocation trace for a running program that is suspected of causing or known to cause memory leaks, the creating comprising retaining, in active memory, a unique object identifier for each of a plurality of objects instantiated during program execution and an address in the active memory where each object is stored; identifying at least one memory leak candidate, the identifying comprising directly examining contents of the active memory to identify one or more data structures that are increasing in size over time; generating information about an identified leaking object, the generating comprising extracting the plurality of objects from the allocation trace as extracted candidate objects, determining for each candidate extracted object of the plurality of candidate objects whether the extracted candidate object is one of the at least one memory leak candidate, and identifying the extracted candidate object as the identified leaking object; and promoting the information about the identified leaking object. |