mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-07 14:24:43 +00:00
std: align(16) main_thread_tls_buffer
Before this change, thread local variables were landmines if LLVM decided to optimize any writes to them using vector instructions.
This commit is contained in:
parent
9b86dde7b9
commit
ad05509930
1 changed files with 1 additions and 1 deletions
|
|
@ -327,7 +327,7 @@ pub fn prepareTLS(area: []u8) usize {
|
||||||
if (tls_tp_points_past_tcb) tls_image.data_offset else tls_image.tcb_offset;
|
if (tls_tp_points_past_tcb) tls_image.data_offset else tls_image.tcb_offset;
|
||||||
}
|
}
|
||||||
|
|
||||||
var main_thread_tls_buffer: [256]u8 = undefined;
|
var main_thread_tls_buffer: [256]u8 align(16) = undefined;
|
||||||
|
|
||||||
pub fn initStaticTLS() void {
|
pub fn initStaticTLS() void {
|
||||||
initTLS();
|
initTLS();
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue