[MDEV-27048] UBSAN: runtime error: shift exponent 32 is too large for 32-bit type 'unsigned int' Created: 2021-11-15 Updated: 2023-11-23 Resolved: 2021-11-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Server |
| Affects Version/s: | 10.7.1, 10.7, 10.8 |
| Fix Version/s: | 10.8.0, 10.7.2 |
| Type: | Bug | Priority: | Blocker |
| Reporter: | Roel Van de Paar | Assignee: | Aleksey Midenkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | affects-tests, corruption, init, memory_exhaustion, regression | ||
| Issue Links: |
|
||||||||
| Description |
|
Leads to:
|
| Comments |
| Comment by Roel Van de Paar [ 2021-11-15 ] | |||||||||||||||||||||||
|
| |||||||||||||||||||||||
| Comment by Marko Mäkelä [ 2021-11-15 ] | |||||||||||||||||||||||
|
cond_entry is defined as uint, which should be 32 bits on every platform on our CI systems. Converting to a 64-bit type before the bit shifting should work. The error was introduced in 10.7.1. | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-17 ] | |||||||||||||||||||||||
|
The issue is much more serious than originally thought. The issue can also be observed in mariadbd (not just mariadb-install-db)
Will lead to the same issue, and a temporary table corruption. InnoDB ad MyISAM both produce the issue.
| |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-17 ] | |||||||||||||||||||||||
|
This issue is observed in many trials, so there are likely many more avenues to produce the corruption and overflow. | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-17 ] | |||||||||||||||||||||||
|
Issue is also seen in different stacks. List of UniqueID's seen so far:
As well as various table corruptions. I can reduce more testcases for any of these if of interest, but I expect the issue is clear thanks to marko's input? | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-17 ] | |||||||||||||||||||||||
|
I wonder why this was not picked up by MTR testing? marko is it due to the reason you stated above? marko & midenok, what can be done so we don't miss these? Thank you | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-17 ] | |||||||||||||||||||||||
|
I have a number of testcase reducers which seem to go OOM quickly. It may be that this change is causing memory exhaustion issues. Will retest after fix. | |||||||||||||||||||||||
| Comment by Aleksey Midenkov [ 2021-11-17 ] | |||||||||||||||||||||||
|
Please review bb-10.7-midenok2 | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-18 ] | |||||||||||||||||||||||
|
Will do another run with this branch now. | |||||||||||||||||||||||
| Comment by Roel Van de Paar [ 2021-11-18 ] | |||||||||||||||||||||||
|
Issue looks fixed in bb-10.7-midenok2, none of the uniqueID's above are showing, and other issues are surfacing now that the runs are not being short-stopped by these blocking issues. | |||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2021-11-19 ] | |||||||||||||||||||||||
|
OK to push |