-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Inline TLS field access for linux/osx x64/arm64 #87082
Conversation
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch |
src/coreclr/jit/helperexpansion.cpp
Outdated
JITDUMP("offsetOfThreadLocalStoragePointer= %u\n", threadStaticBlocksInfo.offsetOfThreadLocalStoragePointer); | ||
JITDUMP("offsetOfMaxThreadStaticBlocks= %u\n", offsetOfMaxThreadStaticBlocksVal); | ||
JITDUMP("offsetOfThreadStaticBlocks= %u\n", offsetOfThreadStaticBlocksVal); | ||
JITDUMP("tlsIndex= %u\n", (ssize_t)threadStaticBlocksInfo.tlsIndex.addr); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dump threadStaticBlocksInfo.tlsIndex.accessType
also?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it will be useful? I don't see we print accessType
elsewhere.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it will be useful? I don't see we print
accessType
elsewhere.
I don't know. Structurally, it seems odd to omit it. Up to you.
Ping @BruceForstall |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM w/ one nit
- Disable dotnet#87082 for RISC-V
Extending #85619 and #82973 for linux.
Base:
Diff:
This also adds
mrs
instruction in arm64 to access TLS on linux. The codegen is:osx/arm64:
Because of register allocator doesn't reuse the
x0
properly, we end up creating the same constant again inx1
, but this is how osx/arm64 looks like:osx/x64: