View Issue Details

IDProjectCategoryView StatusLast Update
0028240Open CASCADEOCCT:Foundation Classespublic2017-09-29 16:31
ReporterabvAssigned Toapn  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Target Version7.2.0Fixed in Version7.2.0 
Summary0028240: Avoid redundant search for span index in evaluation of BSpline cache
DescriptionAs it has been discovered during works on issue 0027074, BSpline evaluation is not optimal as it performs repeated search for span index of BSpline in some cases where it is already available. Avoiding this search allows accelerating BSpline evaluation in some specific cases, e.g. test de step_2 U4: 0.765625 / 38.953125 [-98.03%]
Steps To Reproducetest de step_2 U4
TagsNo tags attached.
Test case numberde step_2 U4

Relationships

child of 0027074 feedbackabv Community Support of multi-span cache in Geom[2d]Adaptor 

Activities

abv

2016-12-18 11:18

manager   ~0061831

Last edited: 2016-12-18 19:49

One observation: this test (de step_2 U4) runs ~ 38 sec if OCCT is built with VC 10 and ~ 17 sec with VC 14 (the same current master and older versions, down to Feb 2016). Apparently the latter has essentially better optimization for this kind of code.

Opposite example is test perf de bug26338_2: ~ 14 sec with vc14 and ~ 11 sec with vc10... magic! Here, the reason is most likely is C++ streams that became much slower since VC 12.

git

2016-12-18 20:26

administrator   ~0061837

Branch CR28240 has been created by abv.

SHA-1: 4a57d7acd8722eca52c67fb0a0e7e2b813c8f4e5


Detailed log of new commits:

Author: abv
Date: Sun Dec 18 09:21:54 2016 +0300

    0028240: Avoid redundant search for span index in evaluation of BSpline cache

abv

2016-12-18 20:36

manager   ~0061838

Fix (extracted from CR27074 branches) is pushed to CR28240, please review.

Notable CPU difference are observed on two tests only (for vc14 64-bit i4790 CPU):

CPU de step_2 U4: 0.6875 / 18.359375 [-96.26%]
CPU perf de bug26338_2: 9.53125 / 14.40625 [-33.84%]

azv

2016-12-19 10:28

administrator   ~0061842

Reviewed, please test.

apv

2016-12-20 14:33

tester   ~0061905

Dear BugMaster,

Branch CR28240 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested.
SHA-1: 4a57d7acd8722eca52c67fb0a0e7e2b813c8f4e5

Number of compiler warnings:
occt component:
   Linux: 0 (0 on master)
   Windows: 0 (0 on master)
   MasOS: 0 (0 on master)
products component:
   Linux: 63
   Windows: 0
   MacOS: 1125

Regressions/Differences:
Not detected

Testing cases:
de step_2 U4 - OK
CPU de step_2 U4: 0.8112052 / 47.8143065 [-98.30%]
http://occt-tests/CR28240-master-OCCT/Debian70-64/de/step_2/U4.html
http://occt-tests/CR28240-master-OCCT/Windows-64-VC10/de/step_2/U4.html

Testing on Linux:
Total MEMORY difference: 93039897 / 92897164 [+0.15%]
Total CPU difference: 21548.070000000203 / 21640.46000000027 [-0.43%]

Testing on Windows:
Total MEMORY difference: 58501245 / 58518712 [-0.03%]
Total CPU difference: 19431.344159098564 / 19818.897443398673 [-1.96%]

git

2017-02-08 11:32

administrator   ~0063567

Branch CR28240 has been deleted by kgv.

SHA-1: 4a57d7acd8722eca52c67fb0a0e7e2b813c8f4e5

Related Changesets

occt: master a061150b

2016-12-18 06:21:54

abv


Committer: apn Details Diff
0028240: Avoid redundant search for span index in evaluation of BSpline cache Affected Issues
0028240
mod - src/Adaptor3d/Adaptor3d_TopolTool.cxx Diff File
mod - src/BSplCLib/BSplCLib.cxx Diff File
mod - src/BSplCLib/BSplCLib.hxx Diff File
mod - src/BSplCLib/BSplCLib_Cache.cxx Diff File
mod - src/BSplCLib/BSplCLib_CurveComputation.gxx Diff File

Issue History

Date Modified Username Field Change
2016-12-18 09:38 abv New Issue
2016-12-18 09:38 abv Assigned To => abv
2016-12-18 09:38 abv Relationship added child of 0027074
2016-12-18 11:18 abv Note Added: 0061831
2016-12-18 19:49 abv Note Edited: 0061831
2016-12-18 20:26 git Note Added: 0061837
2016-12-18 20:36 abv Note Added: 0061838
2016-12-18 20:36 abv Assigned To abv => azv
2016-12-18 20:36 abv Status new => resolved
2016-12-18 20:36 abv Steps to Reproduce Updated
2016-12-19 10:28 azv Note Added: 0061842
2016-12-19 10:28 azv Assigned To azv => bugmaster
2016-12-19 10:28 azv Status resolved => reviewed
2016-12-19 11:05 apv Assigned To bugmaster => apv
2016-12-19 14:12 apv Test case number => de step_2 U4
2016-12-20 14:33 apv Note Added: 0061905
2016-12-20 14:33 apv Assigned To apv => bugmaster
2016-12-20 14:33 apv Status reviewed => tested
2016-12-23 12:09 apn Changeset attached => occt master a061150b
2016-12-23 12:09 apn Assigned To bugmaster => apn
2016-12-23 12:09 apn Status tested => verified
2016-12-23 12:09 apn Resolution open => fixed
2017-02-08 11:32 git Note Added: 0063567
2017-09-29 16:21 aiv Fixed in Version => 7.2.0
2017-09-29 16:31 aiv Status verified => closed