[MDEV-6534] MySQL Bug#72754 - Set thread priority in InnoDB mutex spinloop Created: 2014-08-05 Updated: 2014-09-05 Resolved: 2014-09-05 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Fix Version/s: | 5.5.40, 10.0.14 |
| Type: | Task | Priority: | Major |
| Reporter: | Sergey Vojtovich | Assignee: | Michael Widenius |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
The following patch is suggested by Stewart Smith:
|
| Comments |
| Comment by Michael Widenius [ 2014-08-05 ] | |||||||||||||||||||
|
I would argue that this patch is not needed. Reason:
This should make the original code safe. The other loop also references a volatile argument, so this is also safe. I suggest we don't take this patch (unless someone can show us an assembler output where the loop is optimized away). | |||||||||||||||||||
| Comment by Michael Widenius [ 2014-08-06 ] | |||||||||||||||||||
|
I assume it's ok to add the code to lower cpu priority as long as it's ifdef:ed and only used on power. | |||||||||||||||||||
| Comment by Michael Widenius [ 2014-08-06 ] | |||||||||||||||||||
|
Not that instead of using asm instructions directly, it's better to use proper macros: #ifdef powerpc We could add this to a new file include/cpu.h | |||||||||||||||||||
| Comment by Sergey Vojtovich [ 2014-08-06 ] | |||||||||||||||||||
|
Looks fine, just a few things for your consideration:
| |||||||||||||||||||
| Comment by Sergey Vojtovich [ 2014-09-05 ] | |||||||||||||||||||
|
|