View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0023818 | Open CASCADE | OCCT:Foundation Classes | public | 2013-03-05 17:22 | 2021-03-25 10:21 |
Reporter | Assigned To | ||||
Priority | normal | Severity | feature | ||
Status | closed | Resolution | fixed | ||
Product Version | 6.6.0 | ||||
Target Version | 6.6.0 | Fixed in Version | 6.6.0 | ||
Summary | 0023818: Extend OSD_MemInfo to report C heap statistics | ||||
Description | Currently class OSD_MemInfo is able to report OS-specific memory allocation statistics such as working set, virtual memory etc. These parameters are very dependent on the OS state and thus not reliable for practical use, e.g. for control of memory leaks in automatic tests. It is proposed to add functionality to report statistics on the status of the C heap, which should be more robust. In practice, current total amount of allocated memory should be sufficient. On Windows with MSVCRT, functions heapwalk() can be used to parse through C heap. On Linux with GLibC, function mallinfo() can be used (or even malloc_info() if it works). Then we can add relevant option (e.g. "h" for heap) to DRAW command meminfo and try to use it instead of currently used option "w" in tests for memory leaks control. | ||||
Tags | No tags attached. | ||||
Test case number | Not needed | ||||
parent of | 0023901 | closed | Open CASCADE | Memory leaks in tests | |
parent of | 0032006 | new | Open CASCADE | Foundation Classes - OSD_MemInfo returns negative heap value | |
related to | 0023879 | closed | Open CASCADE | Test cases update for Mac OS X platform | |
Not all the children of this issue are yet resolved or closed. |
|
Dear abv, The fix was pushed to branch CR23818_1. Please, review. |
|
What is a purpose of if at line 93 of OSD_MemInfo.cxx? Should not it just initialize the member by zero? Please convert also other tests that use 'meminfo -w' now, to use of 'meminfo -h' |
|
Dear abv, I've corrected the source code and the testcases. Please, review branch CR23818_1. |
|
No remarks, please test |
|
Dear BugMaster, Branch CR23818_1 (and products from GIT master) was compiled on Linux and Windows platforms and tested without rebase. SHA-1: 8a49a808e0597127df45b74f96833b1914cdbbf0 Number of compiler warnings: occt component : Linux: 3 (3 on master) Windows: 11 (11 on master) products component : Linux: 0 (0 on master) Windows: 50 (50 on master) New additional regressions/differences: http://occt-tests/CR23818-1-master-occt/Mandriva2010/summary.html http://occt-tests/CR23818-1-master-occt/Windows-32-VC9/summary.html bugs caf(015) bug23489 - Memory leak detected bugs moddata_2(012) bug277 - Memory leak detected Improvements: No improvements Testing cases: Not needed Testing on Linux: Total MEMORY difference: 239007532 / 238843232 Total CPU difference: 17035.890000000374 / 16287.660000000136 Testing on Windows: Total MEMORY difference: 352178092 / 351722748 Total CPU difference: 21921.0625 / 20765.75 There are not serious differences in images found by testdiff. |
|
Oleg, please check the reported regressions -- are they really memory leaks? Start by checking the operation performed in the test case |
occt: master 67a1064e 2013-04-12 09:21:13
|
0023818: Extend OSD_MemInfo to report C heap statistics A new counter MemHeapUsage was added to OSD_MemInfo class to examine program heap size DRAW command meminfo got new option -h (--heap ) to use new counter data The following testcases were changed to use new option -h of DRAW command meminfo myCounters[MemHeapUsage] now will always be refilled every time the OSD_MemInfo::Update() function is called. Fixed testcases to use meminfo -h instead of meminfo -w to detect memory leaks more properly. |
Affected Issues 0023818 |
|
mod - src/Draw/Draw_BasicCommands.cxx | Diff File | ||
mod - src/OSD/OSD_MemInfo.cxx | Diff File | ||
mod - src/OSD/OSD_MemInfo.hxx | Diff File | ||
mod - tests/bugs/begin | Diff File | ||
mod - tests/bugs/caf/buc60921 | Diff File | ||
mod - tests/bugs/caf/bug114 | Diff File | ||
mod - tests/bugs/caf/bug23489 | Diff File | ||
mod - tests/bugs/fclasses/bug22611 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_1 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_2 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_3 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_4 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_5 | Diff File | ||
mod - tests/bugs/fclasses/bug7287_6 | Diff File | ||
mod - tests/bugs/moddata_1/bug145 | Diff File | ||
mod - tests/bugs/moddata_1/bug20627 | Diff File | ||
mod - tests/bugs/moddata_2/bug277 | Diff File | ||
mod - tests/bugs/moddata_3/bug162 | Diff File | ||
mod - tests/bugs/vis/bug172 | Diff File | ||
mod - tests/bugs/vis/bug5682 | Diff File | ||
mod - tests/bugs/vis/bug79 | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-03-05 17:22 |
|
New Issue | |
2013-03-05 17:22 |
|
Assigned To | => abv |
2013-03-05 17:22 |
|
Assigned To | abv => omy |
2013-03-05 17:22 |
|
Status | new => assigned |
2013-03-29 14:04 |
|
Note Added: 0023935 | |
2013-03-29 14:04 |
|
Assigned To | omy => abv |
2013-03-29 14:04 |
|
Status | assigned => resolved |
2013-04-01 11:12 |
|
Note Added: 0023947 | |
2013-04-01 11:12 |
|
Status | resolved => assigned |
2013-04-01 13:05 |
|
Assigned To | abv => omy |
2013-04-02 10:41 |
|
Note Added: 0023961 | |
2013-04-02 10:41 |
|
Assigned To | omy => abv |
2013-04-02 10:41 |
|
Status | assigned => resolved |
2013-04-04 06:56 |
|
Note Added: 0023989 | |
2013-04-04 06:56 |
|
Assigned To | abv => bugmaster |
2013-04-04 06:56 |
|
Status | resolved => reviewed |
2013-04-04 14:52 |
|
Assigned To | bugmaster => mkv |
2013-04-05 13:54 |
|
Relationship added | related to 0023879 |
2013-04-05 17:42 |
|
Note Added: 0024021 | |
2013-04-05 17:43 |
|
Test case number | => Not needed |
2013-04-05 17:43 |
|
Assigned To | mkv => abv |
2013-04-05 17:43 |
|
Status | reviewed => feedback |
2013-04-10 08:51 |
|
Note Added: 0024062 | |
2013-04-10 08:51 |
|
Assigned To | abv => omy |
2013-04-10 08:51 |
|
Status | feedback => assigned |
2013-04-15 07:25 |
|
Relationship added | parent of 0023901 |
2013-04-15 17:59 |
|
Changeset attached | => occt master 67a1064e |
2013-04-15 17:59 |
|
Status | assigned => verified |
2013-04-15 17:59 |
|
Resolution | open => fixed |
2013-04-23 13:35 |
|
Status | verified => closed |
2013-04-29 15:24 |
|
Fixed in Version | => 6.6.0 |
2020-12-17 22:26 | kgv | Relationship added | parent of 0032006 |