Merge lp:~vlad-lesin/percona-server/5.6-bug-1351148 into lp:percona-server/5.6
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Laurynas Biveinis | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | 705 | ||||
Proposed branch: | lp:~vlad-lesin/percona-server/5.6-bug-1351148 | ||||
Merge into: | lp:percona-server/5.6 | ||||
Diff against target: |
69 lines (+38/-3) 2 files modified
mysys/lf_alloc-pin.c (+10/-1) mysys/my_thr_init.c (+28/-2) |
||||
To merge this branch: | bzr merge lp:~vlad-lesin/percona-server/5.6-bug-1351148 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Laurynas Biveinis (community) | Approve | ||
Registry Administrators | Pending | ||
Review via email: mp+235721@code.launchpad.net |
Description of the change
Bug #1351128 fix.
The bug's summary:
1) The value in pins->stack_
calculated when the thread is initialized in my_thread_init(). The problem is
that the value doesn't take into account existing stack usage and just adds the
thread stack size to calculate the beginning of the stack.
2) _lf_pinbox_
should only be used by leaf functions, since you cannot predict the amount of
stack space that non-leaf functions will use. As pins->stack_
calculated in wrong way and there is no window for the qsort() which is invoked
from _lf_pinbox_
The solution:
1) Take into accout the current stack offset when stack size is calculated
in my_thread_init();
2) Don't allocate the whole free stack space in _lf_pinbox_
take some window for qsort();
http://
5.6 not merged from the last 5.5 push?