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

TLS alignment lead to a not aligned stack on aarch64 #14

Open
mohamed-karaoui opened this issue Jan 7, 2018 · 2 comments
Open

TLS alignment lead to a not aligned stack on aarch64 #14

mohamed-karaoui opened this issue Jan 7, 2018 · 2 comments

Comments

@mohamed-karaoui
Copy link
Contributor

When using TLS, the size of the section may lead to having a not aligned stack on aarch64: the TLS is allocated at the same time as the stack within pthread_create().

This problem is confirmed by the kernel dmesg message:
"SP Alignment exception: pc=0000000000508d10 sp=00007ffff6b2a9a8"

A test that show the problem is in the "popcorn-test" repos in the "tls-test" test.

Two possible solutions:

  1. Align the TLS section in the LDSCRIPT
  2. Modify the musl library to make sure that the stack is aligned
@rlyerly
Copy link
Collaborator

rlyerly commented Sep 12, 2018

@mohamed-karaoui is this issue now closed?

@mohamed-karaoui
Copy link
Contributor Author

Not sure. I will run the test again on the last master branch, just in case.

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

No branches or pull requests

2 participants