[MDEV-4753] partition_innodb_stmt reports memory leaks from dict/dict0stats_bg.cc:69 Created: 2013-07-04 Updated: 2013-07-04 Resolved: 2013-07-04 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | 10.0.4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Sergei Petrunia | Assignee: | Unassigned |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
openSUSE 11.3 (x86_64) |
||
| Issue Links: |
|
||||||||
| Description |
|
In current 10.0-monty, running ./mysql-test-run main.partition_innodb_stmt produces this output
|
| Comments |
| Comment by Sergei Petrunia [ 2013-07-04 ] |
|
The memory seems to be allocated here: void recalc_pool.reserve(RECALC_POOL_INITIAL_SLOTS); recalc_pool is defined above as: typedef std::vector<table_id_t> recalc_pool_t; There is a corresponding deinit function: dict_stats_recalc_pool_deinit() |
| Comment by Sergei Petrunia [ 2013-07-04 ] |
|
If I put printouts into dict_stats_recalc_pool_init() and dict_stats_recalc_pool_deinit(), the error log shows that _deinit() call is made by the test. Memory leak is still reported. |
| Comment by Sergei Petrunia [ 2013-07-04 ] |
|
Exploration patch: === modified file 'storage/innobase/dict/dict0stats_bg.cc' /** The multitude of tables whose stats are to be automatically + ~recalc_pool_t() + typedef recalc_pool_t::iterator recalc_pool_iterator_t; @@ -76,6 +92,7 @@ dict_stats_recalc_pool_deinit() |
| Comment by Sergei Petrunia [ 2013-07-04 ] |
|
Running with the exploration patch produces this: recalc_pool_t ctor Apparently, the memory is freed in the end, but that happens after the mem leak detector is run. |
| Comment by Sergei Petrunia [ 2013-07-04 ] |
|
Fix pushed into 10.0-monty |