MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0029064Open CASCADE[OCCT] OCCT:Foundation Classespublic2017-08-28 14:272018-06-29 21:19
Reportermpv 
Assigned Tobugmaster 
PrioritynormalSeverityminor 
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version[OCCT] 7.1.0 
Target Version[OCCT] 7.3.0Fixed in Version[OCCT] 7.3.0 
Summary0029064: Copying of empty NCollection map takes excessive memory
Description  NCollection_Map<int> aMap;
creates a map with myNbBuckets=1 and myData1=NULL, minimum memory is allocated

  NCollection_Map<int> aCopyMap = aMap;
produces a map with myNbBuckets=101 and myData1 referenced to newly allocated 816 bytes

  NCollection_Map<int> aCopyCopyMap = aCopyMap;
does the same, but in addition in "Assign" method it iterates all buckets to try to find elements to copy regardless mySize is 0
Steps To Reproduce.
TagsNo tags attached.
Test case numberbugs fclasses bug29064
Attached Files

- Relationships

-  Notes
(0073422)
git (administrator)
2018-01-15 22:44

Branch CR29064 has been created by isn.

SHA-1: c284d392e58eb444a909e6c6ab631bb23adbdc7c


Detailed log of new commits:

Author: isn
Date: Mon Jan 15 20:29:14 2018 +0300

    0029064: Copying of empty NCollection map takes excessive memory
    
    skip resizing of ncollection maps in Assign() methods if given map is empty
(0073447)
git (administrator)
2018-01-16 19:28

Branch CR29064 has been updated forcibly by isn.

SHA-1: d7c4a26c8553c55dab36a849f7283d76099bf828
(0073465)
isn (developer)
2018-01-17 12:42

/view/CR29064-master-isn/
(0073478)
msv (developer)
2018-01-17 15:59

src/NCollection/NCollection_DataMap.hxx
src/NCollection/NCollection_DoubleMap.hxx
src/NCollection/NCollection_IndexedDataMap.hxx
src/NCollection/NCollection_IndexedMap.hxx
- Use the variable anExt to avoid calling theOther.Extent() once again.

src/QABugs/QABugs_20.cxx
- Avoid code duplication using template function.

- Add standard header in the scripts.
- The command pload is not needed in the scripts.
- Make a TCL procedure in the 'begin' file that makes all job and checks memory:
proc CheckMemPeak {script max_memory}
and simplify each script as follows:
CheckMemPeak {OCC29064 m} 15000000
(0073488)
git (administrator)
2018-01-18 14:17

Branch CR29064 has been updated by isn.

SHA-1: 63eb499f64d8a54b85d32932f2d8a4648509263a


Detailed log of new commits:

Author: isn
Date: Thu Jan 18 14:16:47 2018 +0300

    corrections

(0073489)
git (administrator)
2018-01-18 14:22

Branch CR29064 has been updated forcibly by isn.

SHA-1: de3371130798b3bb733c1ba47e76a3baae8a4cc3
(0073497)
isn (developer)
2018-01-18 19:48

test job is same (/view/CR29064-master-isn/)
(0073510)
msv (developer)
2018-01-19 10:47

Please rebase on current master and retest.
(0073530)
git (administrator)
2018-01-19 14:40

Branch CR29064_1 has been created by isn.

SHA-1: 902ec825e0c8a2039e484991b67c5d7a718e41ec


Detailed log of new commits:

Author: isn
Date: Thu Jan 18 14:16:47 2018 +0300

    corrections

Author: isn
Date: Mon Jan 15 20:29:14 2018 +0300

    0029064: Copying of empty NCollection map takes excessive memory
    
    skip resizing of ncollection maps in Assign() methods if given map is empty
(0073538)
isn (developer)
2018-01-19 17:24

rebased,
test job is view/CR29064_1-master-isn/
(0074882)
git (administrator)
2018-03-25 08:41

Branch CR29064_2 has been created by abv.

SHA-1: 3dcc67cbe5ea1f61e4ea655b66894e296ff898da


Detailed log of new commits:

Author: isn
Date: Mon Jan 15 20:29:14 2018 +0300

    0029064: Copying of empty NCollection map takes excessive memory
    
    Avoid resizing of NCollection maps in Assign() methods if source map is empty
(0074887)
abv (manager)
2018-03-25 13:04

Reviewed with amendments, please integrate (branch CR29064_2, test results in Jenkins job CR29064-master-abv).

Some general remarks on implementation of test and DRAWC command:
- For small tests, having single test script is better than several ones (faster, more compact results, easier to control)
- In the code, please use spaces after comma and semicolon, around =, around (but not inside) parentheses and quotes
- Names of function arguments should begin with "the"
- Check availability of the data before using them (in initial implementation DRAW command did not check number of arguments but always used first one)
- In case of wrong arguments, give error message to cout and return 1
(0074888)
git (administrator)
2018-03-25 13:18

Branch CR29064_2 has been updated forcibly by abv.

SHA-1: c33ced0b4f29277d05c56e3a92afd5666db7ae65
(0074890)
abv (manager)
2018-03-25 15:39

(The updated commit just improves some comments and output text in DRAW command)
(0074927)
bugmaster (administrator)
2018-03-26 15:30

Combination -
OCCT branch : CR29064_2 SHA - 3dcc67cbe5ea1f61e4ea655b66894e296ff898da
Products branch : master SHA - da4f0e3aff0376d91aaa652cc2752ed2e0d41ab9
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian70-64:
OCCT
Total CPU difference: 18300.449999999917 / 18135.489999999976 [+0.91%]
Products
Total CPU difference: 7413.520000000004 / 7435.139999999992 [-0.29%]
Windows-64-VC10:
OCCT
Total CPU difference: 17931.394544098617 / 17864.39211459853 [+0.38%]
Products
Total CPU difference: 8190.348901899946 / 8129.77371359997 [+0.75%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0075313)
git (administrator)
2018-04-11 11:00

Branch CR29064 has been deleted by kgv.

SHA-1: de3371130798b3bb733c1ba47e76a3baae8a4cc3
(0075314)
git (administrator)
2018-04-11 11:00

Branch CR29064_1 has been deleted by kgv.

SHA-1: 902ec825e0c8a2039e484991b67c5d7a718e41ec
(0075315)
git (administrator)
2018-04-11 11:00

Branch CR29064_2 has been deleted by kgv.

SHA-1: c33ced0b4f29277d05c56e3a92afd5666db7ae65

- Related Changesets
occt: master 229add78
Timestamp: 2018-01-15 17:29:14
Author: isn
Committer: bugmaster
Details ] Diff ]
0029064: Copying of empty NCollection map takes excessive memory

Avoid resizing of NCollection maps in Assign() methods if source map is empty
mod - src/NCollection/NCollection_DataMap.hxx Diff ] File ]
mod - src/NCollection/NCollection_DoubleMap.hxx Diff ] File ]
mod - src/NCollection/NCollection_IndexedDataMap.hxx Diff ] File ]
mod - src/NCollection/NCollection_IndexedMap.hxx Diff ] File ]
mod - src/NCollection/NCollection_Map.hxx Diff ] File ]
mod - src/QABugs/QABugs_20.cxx Diff ] File ]
add - tests/bugs/fclasses/bug29064 Diff ] File ]

- Issue History
Date Modified Username Field Change
2017-08-28 14:27 mpv New Issue
2017-08-28 14:27 mpv Assigned To => abv
2018-01-10 17:02 abv Assigned To abv => isn
2018-01-10 17:02 abv Status new => assigned
2018-01-15 22:44 git Note Added: 0073422
2018-01-16 14:20 isn Assigned To isn => msv
2018-01-16 14:20 isn Status assigned => resolved
2018-01-16 14:20 isn Steps to Reproduce Updated View Revisions
2018-01-16 19:28 git Note Added: 0073447
2018-01-17 12:42 isn Note Added: 0073465
2018-01-17 15:59 msv Note Added: 0073478
2018-01-17 15:59 msv Assigned To msv => isn
2018-01-17 15:59 msv Status resolved => assigned
2018-01-18 14:17 git Note Added: 0073488
2018-01-18 14:22 git Note Added: 0073489
2018-01-18 19:48 isn Note Added: 0073497
2018-01-18 19:48 isn Assigned To isn => msv
2018-01-18 19:48 isn Status assigned => resolved
2018-01-19 10:47 msv Note Added: 0073510
2018-01-19 10:47 msv Assigned To msv => isn
2018-01-19 10:47 msv Status resolved => assigned
2018-01-19 14:40 git Note Added: 0073530
2018-01-19 17:24 isn Note Added: 0073538
2018-01-19 17:24 isn Assigned To isn => msv
2018-01-19 17:24 isn Status assigned => resolved
2018-01-19 17:25 isn Assigned To msv => isn
2018-01-19 17:25 isn Status resolved => assigned
2018-01-19 17:37 isn Assigned To isn => msv
2018-01-19 17:37 isn Status assigned => resolved
2018-03-14 14:11 abv Target Version 7.4.0* => 7.3.0
2018-03-25 08:41 git Note Added: 0074882
2018-03-25 13:04 abv Note Added: 0074887
2018-03-25 13:04 abv Assigned To msv => bugmaster
2018-03-25 13:04 abv Status resolved => reviewed
2018-03-25 13:18 git Note Added: 0074888
2018-03-25 15:39 abv Note Added: 0074890
2018-03-26 15:30 bugmaster Note Added: 0074927
2018-03-26 15:30 bugmaster Status reviewed => tested
2018-03-26 15:31 bugmaster Test case number => bugs fclasses bug29064
2018-04-11 07:49 bugmaster Changeset attached => occt master 229add78
2018-04-11 07:49 bugmaster Status tested => verified
2018-04-11 07:49 bugmaster Resolution open => fixed
2018-04-11 11:00 git Note Added: 0075313
2018-04-11 11:00 git Note Added: 0075314
2018-04-11 11:00 git Note Added: 0075315
2018-06-29 21:14 user533 Fixed in Version => 7.3.0
2018-06-29 21:19 user533 Status verified => closed


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker