View Issue Details

IDProjectCategoryView StatusLast Update
0013189Open CASCADEOCCT:Foundation Classespublic2012-01-13 17:08
ReporterabvAssigned Toabv 
PrioritynormalSeverityfeature 
Status closedResolutionfixed 
OSAll 
Fixed in Version6.1.1 
Summary0013189: Optimize OCC maps for work with big amounts of data
DescriptionCurrent implementation of maps in OCCT (see TCollection.cxx) has a limitation
on number of buckets around 100 000. This means that when number of elements in
the map grows above that number, map does not resize any more, and performance
of accessing its elements descreases.

Nowadays we often work with projects where amount of data items (e.g. mesh
elements) is comparable or above this limit.

Therefore it is proposed to extend this limit to at least 1 000 000.

Another proposed improvement is to have less number of steps for resizing.
Currently the steps of resizing are not big (~10% for small sizes). Though this
saves size for buckets array allocation, it also leads to more often
reallocation, especially for big amount of elements (several thousand elements
).

In fact, memory saving is not so big here: taken that each map node occupies ~
24 bytes (taking into account also overhead of OCC memory allocator), while
cell of the buckets array is 4 bytes, saving on reallocation of buckets array
by 10% instead of 2 times is only ~15% of the total map size (besides the data
!).

Thus it is proposed to have less steps for reallocation, mainly trying to have
each next step nearly twice as big as prtevious.
Additional information
and documentation updates
Documentation remark, added by ABV 2006-08-15 13:40:05:

New features:


Improvements:
The size of bucket arrays in implementation of hash maps in both TCollection
and NCollection packages has been optimized to increase performance, especially
for big numbers of items (100K - 1M and more).

Changes:


Modified entities:

TagsNo tags attached.
Test case number

Attached Files

  • occ13189-abv-v1.tar.gz (2,189 bytes)
  • occ13189-abv-test.tar.gz (1,064 bytes)
  • testmaps.xls (40,448 bytes)
  • occ13189-abv-v2.tar.gz (3,329 bytes)

Activities

2006-08-14 15:38

 

occ13189-abv-v1.tar.gz (2,189 bytes)

2006-08-14 15:39

 

occ13189-abv-test.tar.gz (1,064 bytes)

2006-08-14 15:40

 

testmaps.xls (40,448 bytes)

2006-08-15 13:35

 

occ13189-abv-v2.tar.gz (3,329 bytes)

Issue History

Date Modified Username Field Change
2006-08-15 15:33 bugmaster Assigned To bugmaster => abv
2006-08-15 15:33 bugmaster Status new => assigned
2006-08-15 15:36 abv Status assigned => resolved
2006-08-18 18:05 mkv CC => msv
2006-08-21 17:28 mkv Status resolved => tested
2006-09-06 09:31 bugmaster Status tested => verified
2006-11-01 18:20 bugmaster Status verified => closed
2006-11-01 18:20 bugmaster Resolution @0@ => fixed
2011-08-02 11:23 bugmaster Category OCCT:FDC => OCCT:Foundation Classes
2012-01-13 17:08 atp Description Updated
2012-01-13 17:08 atp Additional Information Updated