[YANGTOOLS-1376] Do not retain singleton RangeSets Created: 04/Dec/21  Updated: 04/Dec/21  Resolved: 04/Dec/21

Status: Resolved
Project: yangtools
Component/s: model-ri
Affects Version/s: None
Fix Version/s: 8.0.0

Type: Improvement Priority: Medium
Reporter: Robert Varga Assignee: Robert Varga
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: Parser Performance

 Description   

Heap analysis shows we are retaining ImmutableRangeSets, which are backed by a SingletonImmutableList. This is not terribly bad, but still costs us some 32K retained objects which we can easility re-create on demand. Update Resolved{Length,Range}Constraint to retain only a Range for the common case of having a single available range.


Generated at Wed Feb 07 20:55:58 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.