Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A debug allocator which removes overalignment from align < 8 allocations #99074

Closed
wants to merge 1 commit into from

Commits on Aug 12, 2022

  1. Remove overalignment from align < 8 allocations

    This reorganizes the implementation of the System allocator to permit
    adding various debuggig features. Currently, all that this implements is
    a scheme that allocates a little extra space for low-alignment
    allocations then returns a pointer into the actual allocation which is
    offset so that it is not over-aligned.
    
    This is a huge aid in discovering accidental reliance on over-alignment.
    Allocators designed for C can be relied upon to produce over-aligned
    pointers, so alignment-related bugs can be latent for a long time.
    
    This implementation is also factored so accommodate other patches to the
    default allocator which can help in detecting other sources of UB.
    saethlin committed Aug 12, 2022
    Configuration menu
    Copy the full SHA
    d641a1d View commit details
    Browse the repository at this point in the history