Skip to content

Conversation

@jberthold
Copy link
Member

To solve #638 , there are several possibilities:

  1. implement a pointer emulation which is aware of the underlying alignment: A pointer->usize cast should return an address which is aligned in the way that the pointer (possibly after an offset and casts to different pointer types) requires.
  2. recognise the entire block responsible for the alignment check and rewrite it to a K sequence performing an equivalent alignment check.

This PR takes the first step for option 2, recognising (and for now skipping) the alignment-checking block as a whole.

- plus test program having this block of code which previously failed

Related: #638
@jberthold jberthold force-pushed the 638-skip-alignment-checking-block branch from adc3c7f to 2f85a74 Compare December 3, 2025 22:46
@jberthold jberthold linked an issue Dec 3, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extend pointer emulation to pass alignment check

2 participants