Skip to content

arc: Set tp regno to 26 for Zephyr #17

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

Open
wants to merge 1 commit into
base: zephyr-gcc-12.1.0
Choose a base branch
from

Conversation

keith-packard
Copy link
Collaborator

Zephyr needs a consistent thread pointer register which is respected by all code, not just the OS.

Signed-off-by: Keith Packard [email protected]

@stephanosio
Copy link
Member

stephanosio commented Nov 2, 2022

@abrodkin @evgeniy-paltsev @claziss does this sound ok?

@claziss
Copy link

claziss commented Nov 3, 2022

@stephanosio From compiler point of view, you can choose any callee saved register (i.e. r14-r30, excluding blink, sp,fp, and ilink).

Zephyr needs a consistent thread pointer register which is respected
by all code, not just the OS. Use register 26 to be compatible with
existing Zephyr source.

Signed-off-by: Keith Packard <[email protected]>
@keith-packard
Copy link
Collaborator Author

@stephanosio suggests using register 26 so that existing the Zephyr source will 'just work' as it includes -mtp-regno=26 in the build scripts.

@stephanosio
Copy link
Member

@stephanosio suggests using register 26 so that existing the Zephyr source will 'just work' as it includes -mtp-regno=26 in the build scripts.

For more context, see zephyrproject-rtos/zephyr#51910 (comment)

@keith-packard keith-packard changed the title arc: Set tp regno to 25 for Zephyr arc: Set tp regno to 26 for Zephyr Nov 3, 2022
@stephanosio
Copy link
Member

@evgeniy-paltsev Since the transition from r26 to r25 will be implemented later, can you please approve this for now so that we can have TLS working with the toolchain libraries?

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

Successfully merging this pull request may close these issues.

4 participants