mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 22:04:21 +00:00
std.os.windows.tls: Only define _tls_array when targeting MSVC.
LLVM does not use it when emitting code for the MinGW ABI.
This commit is contained in:
parent
0f1db90198
commit
1d8fca0060
1 changed files with 1 additions and 1 deletions
|
|
@ -9,7 +9,7 @@ export var __xl_a: windows.PIMAGE_TLS_CALLBACK linksection(".CRT$XLA") = null;
|
|||
export var __xl_z: windows.PIMAGE_TLS_CALLBACK linksection(".CRT$XLZ") = null;
|
||||
|
||||
comptime {
|
||||
if (builtin.target.cpu.arch == .x86 and builtin.zig_backend != .stage2_c) {
|
||||
if (builtin.cpu.arch == .x86 and builtin.abi == .msvc and builtin.zig_backend != .stage2_c) {
|
||||
// The __tls_array is the offset of the ThreadLocalStoragePointer field
|
||||
// in the TEB block whose base address held in the %fs segment.
|
||||
asm (
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue