Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

ahatanak
Copy link
Collaborator

enable_execute_stack is not supported on arm64 Darwin because:

  • It calls mprotect with PROT_WRITE | PROT_EXEC, which is rejected on this platform.
  • It assumes a fixed 4K page size, which is not guaranteed.

This change disables building enable_execute_stack on arm64 Darwin and fixes the failing test:

compiler-rt/test/builtins/Unit/enable_execute_stack_test.c.

rdar://159705691

`enable_execute_stack` is not supported on arm64 Darwin because:

- It calls mprotect with `PROT_WRITE | PROT_EXEC`, which is rejected on
  this platform.
- It assumes a fixed 4K page size, which is not guaranteed.

This change disables building `enable_execute_stack` on arm64 Darwin and
fixes the failing test:

`compiler-rt/test/builtins/Unit/enable_execute_stack_test.c`.

rdar://159705691
Copy link
Member

@compnerd compnerd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if it was just the page size, that could be adjusted. Android will need 16k pages as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants