Closed Bug 52402 Opened 26 years ago Closed 26 years ago

Image cache grows without bounds

Categories

(Core :: Graphics: ImageLib, defect, P3)

PowerPC
Mac System 8.5
defect

Tracking

()

VERIFIED INVALID

People

(Reporter: sfraser_bugs, Assigned: pnunn)

References

Details

(Keywords: memory-leak, Whiteboard: [nsbeta3-][dogfood-])

Currently the image cache seems to grow without bounds; I see no code that would, on adding a new image to the cache, flush older cache entries to keep the image cache within the specified size. This really hurts Mac, because the heap gets filled up with GWorld data and we crash.
Note that cache entries _do_ get removed when their image containers are deleted on page teardown, so this bug does not lead to a continual increase in memory usage. However, opening lots of windows with many images does cause the cache to grow unbounded, and of course chrome images are never flushed right now.
Keywords: dogfood, nsbeta3
Status: NEW → ASSIGNED
Target Milestone: --- → M18
Blocks: 20743
To try to answer the dogfood question, is this "Leak" activity a dominant reason for a crash, and hence a real dominant reason to not use Nav?
Keywords: mlk
Whiteboard: [NEED INFO]
Yes, this leak is a direct cause of 'out of memory' crashes on Mac. Other changes make the Mac less susceptible to out of memory conditions, but they only got checked in today. We need some stress testing to see if this bug needs fixing.
Based on Simon's comment, it sounds like we need some stress re-testing to see the impact of this problem. It is not clear that this is a stopper, so I'm marking it dogfood-minus. It would be good to get the testing info, and use that as input to the beta3 triage.
Whiteboard: [NEED INFO] → [dogfood-]
This bug causes Mac to crash by running out of memory. It needs fixing.
Whiteboard: [dogfood-]
part of this should get covered by pnunn's recent fix for blocking huge images from being cached. bug 47660. But I agree that this is important to fix. (though not a P2)
Whiteboard: [nebeta3+][dogfood-]
Whiteboard: [nebeta3+][dogfood-] → [nsbeta3+][dogfood-]
I have been seeing the chached images mixed up and displayed in wrong pages (bug 50357). Is this bug related to that one? 50357 has been left as unconfirmed for some time now.
Updating QA Contact
QA Contact: paw → tpreston
Not holding PR3 for this, marking nsbeta3-. Please nominate for rtm if we really need to fix this before shipping Seamonkey.
Whiteboard: [nsbeta3+][dogfood-] → [nsbeta3-][dogfood-]
il_cache.bytes keeps track of bytes currently in use by imgcache. il_cache.max_bytes keeps track of the largest size requested for allocation in the image cache. It is a 'high water' mark. This value DOES NOT mean the imgcache is growing without bounds. If a very large image is requested, currently there is no code that prevents its addition to the image cache. It would cause a purging of the cache to unload images. This means the cache can temporarily go over its 2M upper limit. marking Invalid. -pn
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → INVALID
Please note: The mac's memory problems should be addressed by bug#47660.
As per pnunn's comments, I am marking verified
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.