You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The calculations for total available heap size for user
allocations didn't take all possible metadata into account,
leading to situations where for certain heap sizes
the zone size was too large by a chunk.
To hit this problem the pool has to be almost full. The heap size calculation can be off by 1kB. There's 1/256 chance of hitting this problem for randomly sized pool. However, for pools whose size is a multiple of 1MB (1048576 bytes), the problem doesn't occur.
PMDK 1.8 fixes this problem for newly created pools. The fix for pools created with older versions will be part of PMDK 1.8.1, along with patches for previous stable branches.
For now, the workaround for this problem in the case of pools on FSDAX is to manually extend the pool by 1kB. Pools on Device DAX with default alignment (2MB) are not affected because theirs sizes must be a multiple of 1MB. For pools on Device DAX with 4kB alignment, there's no known workaround if the problem has been hit.
marcinslusarz
changed the title
Memory allocated by pmemobj_tx_xalloc is partially outside the pool
obj: allocation is partially outside the pool
Jan 31, 2020
ISSUE: obj: allocation is partially outside the pool
Environment Information
Please provide a reproduction of the bug:
Reproduction is available here: https://github.com/igchor/obj_repro
Accessing memory returned by pmemobj_tx_xalloc causes segfault.
How often bug is revealed: (always, often, rare):
rare - only if pool has certain size and with specific allocation sizes
Actual behavior:
Segfault when accessing memory
Expected behavior:
No segfault, memory is within the pool
Details
Allocator did not take the size of all possible metadata when calculating total available heap size for user allocations.
Additional information about Priority and Help Requested:
Are you willing to submit a pull request with a proposed change? (Yes, No)
Requested priority: (Showstopper, High, Medium, Low)
The text was updated successfully, but these errors were encountered: