View Issue Details

IDProjectCategoryView StatusLast Update
0022584CommunityOCCT:Meshpublic2012-11-09 10:17
ReporterszyAssigned ToRoman Lygin  
PrioritynormalSeverityfeature 
Status closedResolutionfixed 
OSAll 
Target Version6.5.2Fixed in Version6.5.2 
Summary0022584: Optimization of BRepMesh_DiscretFactory to cache registered factory methods
DescriptionRLN contribution (RLN_fix370)
- Summary: Optimization of BRepMesh_DiscretFactory to cache registered factory
methods
- Detailed description: In 6.3.1 any custom factory method (*::Discret()) is
loaded from dynamic library
        upon every call to mesher. This was extremely slow and made the
mechanism unusable.
        Now library is loaded only once and then its factory method is cached in
_DiscretFactory.
        - This requires adding an instance of DataMap<AsciiString,OSD_Function>.
To optimize it is added into
          OSD package and Draw and Plugin packages reuse it.
TagsNo tags attached.
Test case numberno need for test case

Relationships

related to 0022600 closedbugmaster TBB has to be disabled in BRepMesh due to data races 
child of 0022825 closedabv Integration of contributions by Roman Lygin to OCCT 6.5.2 

Activities

kgv

2011-06-16 12:18

developer   ~0017628

While this patch introduce plugins functions caching (thus eliminates linkage
with plugin and retrieving function address on each call to the factory) it
doesn't resolve another serious issure with current factory architecture.

BRepMesh_DiscretFactory::Discret() returns private field myPDiscret of class
instance that intended to be global (BRepMesh_DiscretFactory&
BRepMesh_DiscretFactory::Get()). This makes factory absolutely unsafe for
calling from multiple threads. I think this major problem should be fixed
within this performance improvement.

Suggested solution to return handle instead of pointer within this method
(BRepMesh_PDiscretRoot could be redefined to be handle to avoid changes in
applications) and probably introduce mutex to ensure thread-safety on first
call when plugin changed.

kgv

2011-06-23 18:31

developer   ~0017629

Suggested improvements are implemented in OCC22600 BUG

Issue History

Date Modified Username Field Change
2011-06-23 18:31 kgv OtherBugsDependingOnThis => 22600
2011-07-05 18:11 kgv CC => kgv
2011-08-02 11:31 bugmaster Category OCCT:MOA => OCCT:Modeling Algorithms
2011-09-13 09:27 abv Test case number => no need for test case
2011-09-13 09:27 abv Status acknowledged => verified
2011-09-13 09:27 abv Fixed in Version EMPTY =>
2011-09-13 09:27 abv Resolution suspended => fixed
2011-09-13 09:27 abv Assigned To bugmaster => kgv
2011-09-20 17:22 szy Target Version => 6.5.2
2011-09-20 17:22 szy Description Updated
2011-11-25 11:46 szy Description Updated
2011-12-05 11:22 abv Relationship added child of 0022825
2012-01-17 18:37 abv Assigned To kgv => Roman Lygin
2012-11-09 10:17 abv Category OCCT:Modeling Algorithms => OCCT:Mesh