Project

Profile

Help

Bug #2820

closed

Location information locks source stylesheet tree into memory

Added by Michael Kay almost 8 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
Performance
Sprint/Milestone:
-
Start date:
2016-07-04
Due date:
% Done:

100%

Estimated time:
Legacy ID:
Applies to branch:
Fix Committed on Branch:
10
Fixed in Maintenance Release:
Platforms:

Description

Not confirmed, but from looking at the code, when we compile an instruction, e.g. XSLElement.compile(), we set location information on the compiled instruction by calling StyleElement.allocateLocation(), and this uses the StyleElement itself as the Location object. This means that the source XSLT tree is referenced from the compiled expression tree, and cannot be garbage collected.

When fixing this, we need to check that there aren't any other links holding the source stylesheet tree in memory. At one time the code was carefully designed to avoid this but there may have been other lapses, since it's difficult to test.

It may be appropriate for the Location object to be the source element in cases where tracing is enabled, to make life easier for debuggers.

Please register to edit this issue

Also available in: Atom PDF