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

Constify is_aligned via align_offset #102795

Merged
merged 20 commits into from
Nov 19, 2022

Commits on Nov 19, 2022

  1. constify exact_div intrinsic

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    f13c4f4 View commit details
    Browse the repository at this point in the history
  2. unify inherent impls of CompileTimeEvalContext

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    f770fec View commit details
    Browse the repository at this point in the history
  3. make const align_offset useful

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    211743b View commit details
    Browse the repository at this point in the history
  4. add coretests for const align_offset

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    8cf6b16 View commit details
    Browse the repository at this point in the history
  5. constify pointer::is_aligned{,_to}

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    6f6320a View commit details
    Browse the repository at this point in the history
  6. add coretests for is_aligned

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    2ef9a8a View commit details
    Browse the repository at this point in the history
  7. mark align_offset as #[must_use]

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    24e8806 View commit details
    Browse the repository at this point in the history
  8. don't call align_offset during const eval, ever

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    a906f6c View commit details
    Browse the repository at this point in the history
  9. document is_aligned{,_to}

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    093c02e View commit details
    Browse the repository at this point in the history
  10. address more review comments

    * `cfg` only the body of `align_offset`
    * put explicit panics back
    * explain why `ptr.align_offset(align) == 0` is slow
    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    df0bcfe View commit details
    Browse the repository at this point in the history
  11. Schrödinger's pointer

    It's aligned *and* not aligned!
    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    4696e89 View commit details
    Browse the repository at this point in the history
  12. always use align_offset in is_aligned_to + add assembly test

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    daccb8c View commit details
    Browse the repository at this point in the history
  13. docs cleanup

    * Fix doc examples for Platforms with underaligned integer primitives.
    * Mutable pointer doc examples use mutable pointers.
    * Fill out tracking issue.
    * Minor formatting changes.
    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    8a60536 View commit details
    Browse the repository at this point in the history
  14. replace potential ICE with graceful error (no_core only)

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    60f352f View commit details
    Browse the repository at this point in the history
  15. fix assembly test on windows

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    8717455 View commit details
    Browse the repository at this point in the history
  16. fix const align_offset implementation

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    9e5d497 View commit details
    Browse the repository at this point in the history
  17. Revert "don't call align_offset during const eval, ever"

    This reverts commit f3a577bfae376c0222e934911865ed14cddd1539.
    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    3d7e9c4 View commit details
    Browse the repository at this point in the history
  18. Update comment on pointer-to-usize transmute

    Co-authored-by: Ralf Jung <[email protected]>
    2 people authored and Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    e90d15b View commit details
    Browse the repository at this point in the history
  19. fix assembly test on apple

    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    53c2ee8 View commit details
    Browse the repository at this point in the history
  20. update provenance test

    * fix allocation alignment for 16bit platforms
    * add edge case where `stride % align != 0` on pointers with provenance
    Lukas Markeffsky committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    c9c017d View commit details
    Browse the repository at this point in the history