Closed Bug 1637734 Opened 5 years ago Closed 1 year ago

Make leakcheck try to filter the list of classes it shows

Categories

(Testing :: General, task, P3)

Version 3
task

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: mccr8, Unassigned)

References

(Blocks 1 open bug)

Details

leakcheck prints out a list of classes that are leaked. It orders the list in alphabetical order, and prints out the first half dozen of them. This is fine for small leaks that only include a few things, but with larger leaks the classes are fairly useless.

Two problems with this are:

  • In bug 1569708 comment 43, kats complains that "APZ gets blamed for all these leaks because the objects are listed in alphabetical order" and classes like APZEventState are often at the front.
  • It makes it harder to tell that different leaks might be the same. If a class is added, removed or renamed and is near the start of the alphabet, then the "signature" will change for the purpose of TreeHerder starring. It can also make the same leak look different on different platforms. I saw a case recently where the Windows version of the leak had Direct3D as one of the leaked objects, whereas of course the Linux version did not.
  • It makes it harder to assess the severity of a leak. A leak that involves a DOM window or document is usually worse than one that just involves some network channels that didn't get torn down properly at shutdown.

I'm not sure what the best way to improve this situation. I was thinking there could be an allow list of important classes. The list of leaked classes would be filtered, and if that found any then you'd use that list (alphabetized as usual).

Severity: -- → S3
Priority: -- → P3

In addition to only mentioning windows and documents, if present, it would probably be a good idea to just say something like "big leak" if there is a leak that involves many different types of objects that does not include either. I'm hoping to get a chance to work on this and other leak checking improvements in the second half of 2021.

Blocks: 1715080
See Also: → 1715090

:mccr8, given the recent changes to leakcheck (large leaks, add dirs), is there something else here specific you would like to see?

Flags: needinfo?(continuation)

Yeah, I think the "big leak" stuff is good enough.

Status: NEW → RESOLVED
Closed: 1 year ago
Flags: needinfo?(continuation)
Resolution: --- → WORKSFORME

I think in practice we have leaks with a handful of objects, and leaks that include windows or backstage passes, so things should be neat enough with the big leaks dealing with the latter.

You need to log in before you can comment on or make changes to this bug.