Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • K kernel
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 26
    • Issues 26
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • redox-osredox-os
  • kernel
  • Merge requests
  • !143

Statically verify that addresses are page-aligned

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed jD91mZM2 requested to merge jD91mZM2/kernel:page-aligned into master Aug 07, 2020
  • Overview 0
  • Commits 4
  • Pipelines 0
  • Changes 8

A bit of an experiment, because I'm not really happy with fmap/funmap's rounding because it's not obvious what is already page-aligned and what isn't.

This data type will only ever hold page-aligned numbers (numbers that are divisible by PAGE_SIZE). The runtime check/rounding is executed once, and after that the type-checker takes over to ensure we only perform safe actions.

This type offers a way to add/subtract multiples while retaining the page-aligned type, since kx + ky = kz. More safe operations should be implemented, as needed.

The goal for this type is to slowly consume more parts of Redox OS' memory logic, eventually making it easy to verify with a simple glance that code is correct.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: page-aligned