Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 5.0.2
-
Fix Version/s: 5.0.3
-
Component/s: Core/Parsing
-
Labels:None
-
Environment:any
Description
A few users have point at this but I thin I finally found the cause. When working though a large document there is an eventual slow down and there is a lot of time spent doing garbage collection. As a result of this collection the UI feels really slow.
I kicked the tires a bit and found that the we are using Softreferences for just about everying, which make it hard for the garbage collector to know what to do.
I kicked the tires a bit and found that the we are using Softreferences for just about everying, which make it hard for the garbage collector to know what to do.
I updated the Library's ConcurrentHashMap for refs and lookupReference2ICCBased to use WeakReferences to give the GC a better hint of what can be pruned. As a result of this simple change the UI is buttery smooth while scrolling through a document with thousands of pages. The memory usage also seems to stay much further below the max memory.