@ttsc/linux-arm 0.14.0-dev.20260529.2 → 0.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (120) hide show
  1. package/bin/go/VERSION +2 -2
  2. package/bin/go/bin/go +0 -0
  3. package/bin/go/bin/gofmt +0 -0
  4. package/bin/go/pkg/tool/linux_arm/asm +0 -0
  5. package/bin/go/pkg/tool/linux_arm/cgo +0 -0
  6. package/bin/go/pkg/tool/linux_arm/compile +0 -0
  7. package/bin/go/pkg/tool/linux_arm/cover +0 -0
  8. package/bin/go/pkg/tool/linux_arm/fix +0 -0
  9. package/bin/go/pkg/tool/linux_arm/link +0 -0
  10. package/bin/go/pkg/tool/linux_arm/preprofile +0 -0
  11. package/bin/go/pkg/tool/linux_arm/vet +0 -0
  12. package/bin/go/src/archive/tar/format.go +6 -0
  13. package/bin/go/src/archive/tar/reader.go +24 -4
  14. package/bin/go/src/builtin/builtin.go +13 -4
  15. package/bin/go/src/crypto/fips140/fips140.go +6 -0
  16. package/bin/go/src/crypto/internal/fips140/drbg/entropy_fips140.go +97 -0
  17. package/bin/go/src/crypto/internal/fips140/drbg/entropy_wasm.go +11 -0
  18. package/bin/go/src/crypto/internal/fips140/drbg/rand.go +1 -75
  19. package/bin/go/src/crypto/tls/conn.go +7 -3
  20. package/bin/go/src/crypto/tls/handshake_client_tls13.go +2 -2
  21. package/bin/go/src/crypto/tls/handshake_server_tls13.go +2 -2
  22. package/bin/go/src/crypto/tls/key_schedule.go +24 -3
  23. package/bin/go/src/crypto/x509/constraints.go +33 -33
  24. package/bin/go/src/crypto/x509/verify.go +28 -13
  25. package/bin/go/src/go/types/builtins.go +2 -2
  26. package/bin/go/src/go/types/signature.go +3 -0
  27. package/bin/go/src/go/types/under.go +3 -3
  28. package/bin/go/src/go.mod +1 -1
  29. package/bin/go/src/go.sum +2 -2
  30. package/bin/go/src/html/template/attr_string.go +3 -2
  31. package/bin/go/src/html/template/context.go +21 -1
  32. package/bin/go/src/html/template/element_string.go +3 -2
  33. package/bin/go/src/html/template/escape.go +16 -2
  34. package/bin/go/src/html/template/js.go +1 -0
  35. package/bin/go/src/html/template/state_string.go +5 -3
  36. package/bin/go/src/html/template/transition.go +43 -6
  37. package/bin/go/src/internal/buildcfg/zbootstrap.go +1 -1
  38. package/bin/go/src/internal/godebugs/table.go +1 -0
  39. package/bin/go/src/internal/poll/fd_windows.go +64 -38
  40. package/bin/go/src/internal/poll/fstatat_unix.go +22 -0
  41. package/bin/go/src/internal/poll/sendfile_windows.go +3 -1
  42. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_386.go +1 -0
  43. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_amd64.go +1 -0
  44. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_arm.go +1 -0
  45. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_arm64.go +1 -0
  46. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_loong64.go +1 -0
  47. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_mips64x.go +1 -0
  48. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_mipsx.go +1 -0
  49. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_ppc64x.go +1 -0
  50. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_riscv64.go +1 -0
  51. package/bin/go/src/internal/runtime/syscall/linux/defs_linux_s390x.go +1 -0
  52. package/bin/go/src/internal/runtime/syscall/linux/syscall_linux.go +14 -0
  53. package/bin/go/src/internal/syscall/unix/at.go +0 -17
  54. package/bin/go/src/internal/syscall/unix/at_sysnum_linux.go +2 -1
  55. package/bin/go/src/internal/syscall/unix/fchmodat_linux.go +51 -0
  56. package/bin/go/src/internal/syscall/unix/fchmodat_other.go +29 -0
  57. package/bin/go/src/internal/syscall/windows/at_windows.go +20 -3
  58. package/bin/go/src/internal/syscall/windows/registry/key.go +10 -2
  59. package/bin/go/src/internal/syscall/windows/registry/value.go +5 -1
  60. package/bin/go/src/internal/syscall/windows/syscall_windows.go +4 -0
  61. package/bin/go/src/internal/syscall/windows/types_windows.go +82 -0
  62. package/bin/go/src/internal/syscall/windows/zsyscall_windows.go +27 -0
  63. package/bin/go/src/net/cgo_unix.go +4 -1
  64. package/bin/go/src/net/http/doc.go +0 -1
  65. package/bin/go/src/net/http/h2_bundle.go +3 -3
  66. package/bin/go/src/net/http/httputil/reverseproxy.go +14 -0
  67. package/bin/go/src/net/lookup_windows.go +16 -3
  68. package/bin/go/src/net/mail/message.go +20 -9
  69. package/bin/go/src/net/sendfile.go +2 -0
  70. package/bin/go/src/net/sendfile_stub.go +2 -0
  71. package/bin/go/src/net/sendfile_windows.go +3 -0
  72. package/bin/go/src/net/url/url.go +22 -16
  73. package/bin/go/src/os/dir_darwin.go +2 -2
  74. package/bin/go/src/os/dir_unix.go +2 -2
  75. package/bin/go/src/os/file.go +0 -3
  76. package/bin/go/src/os/file_unix.go +9 -5
  77. package/bin/go/src/os/removeall_at.go +6 -2
  78. package/bin/go/src/os/removeall_unix.go +0 -8
  79. package/bin/go/src/os/removeall_windows.go +0 -4
  80. package/bin/go/src/os/root_unix.go +1 -0
  81. package/bin/go/src/os/stat.go +3 -0
  82. package/bin/go/src/os/statat.go +24 -0
  83. package/bin/go/src/os/statat_other.go +12 -0
  84. package/bin/go/src/os/statat_unix.go +20 -0
  85. package/bin/go/src/reflect/value.go +3 -2
  86. package/bin/go/src/runtime/defs_linux_386.go +4 -3
  87. package/bin/go/src/runtime/defs_linux_arm.go +4 -3
  88. package/bin/go/src/runtime/defs_linux_mips64x.go +1 -1
  89. package/bin/go/src/runtime/defs_linux_mipsx.go +5 -4
  90. package/bin/go/src/runtime/malloc.go +1 -53
  91. package/bin/go/src/runtime/mem.go +104 -9
  92. package/bin/go/src/runtime/metrics/doc.go +5 -0
  93. package/bin/go/src/runtime/os_linux.go +62 -0
  94. package/bin/go/src/runtime/os_linux32.go +14 -24
  95. package/bin/go/src/runtime/os_linux64.go +2 -0
  96. package/bin/go/src/runtime/print.go +16 -4
  97. package/bin/go/src/runtime/race/README +9 -9
  98. package/bin/go/src/runtime/race/internal/amd64v1/race_darwin.patch +63 -0
  99. package/bin/go/src/runtime/race/internal/amd64v1/race_darwin.syso +0 -0
  100. package/bin/go/src/runtime/race/internal/amd64v1/race_freebsd.patch +63 -0
  101. package/bin/go/src/runtime/race/internal/amd64v1/race_freebsd.syso +0 -0
  102. package/bin/go/src/runtime/race/internal/amd64v1/race_linux.patch +63 -0
  103. package/bin/go/src/runtime/race/internal/amd64v1/race_linux.syso +0 -0
  104. package/bin/go/src/runtime/race/internal/amd64v1/race_windows.patch +63 -0
  105. package/bin/go/src/runtime/race/internal/amd64v1/race_windows.syso +0 -0
  106. package/bin/go/src/runtime/race/internal/amd64v3/race_linux.patch +63 -0
  107. package/bin/go/src/runtime/race/internal/amd64v3/race_linux.syso +0 -0
  108. package/bin/go/src/runtime/race/race_darwin_arm64.patch +63 -0
  109. package/bin/go/src/runtime/race/race_darwin_arm64.syso +0 -0
  110. package/bin/go/src/runtime/race/race_linux_arm64.patch +63 -0
  111. package/bin/go/src/runtime/race/race_linux_arm64.syso +0 -0
  112. package/bin/go/src/runtime/race/race_linux_loong64.patch +63 -0
  113. package/bin/go/src/runtime/race/race_linux_loong64.syso +0 -0
  114. package/bin/go/src/runtime/race/race_linux_s390x.patch +63 -0
  115. package/bin/go/src/runtime/race/race_linux_s390x.syso +0 -0
  116. package/bin/go/src/syscall/syscall_windows.go +5 -1
  117. package/bin/go/src/vendor/modules.txt +1 -1
  118. package/bin/ttsc +0 -0
  119. package/bin/ttscserver +0 -0
  120. package/package.json +1 -1
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -0,0 +1,63 @@
1
+ From cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca Mon Sep 17 00:00:00 2001
2
+ From: Michael Pratt <michael@prattmic.com>
3
+ Date: Fri, 12 Dec 2025 16:31:44 +1100
4
+ Subject: [PATCH] [TSan] Zero-initialize Trace.local_head
5
+
6
+ Trace.local_head is currently uninitialized when Trace is created. It is
7
+ first initialized when the first event is added to the trace, via the
8
+ first call to TraceSwitchPartImpl.
9
+
10
+ However, ThreadContext::OnFinished uses local_head, assuming that it is
11
+ initialized. If it has not been initialized, we have undefined behavior,
12
+ likely crashing if the contents are garbage. The allocator (Alloc)
13
+ reuses previously allocations, so the contents of the uninitialized
14
+ memory are arbitrary.
15
+
16
+ In a C/C++ TSAN binary it is likely very difficult for a thread to start
17
+ and exit without a single event inbetween. For Go programs, code running
18
+ in the Go runtime itself is not TSan-instrumented, so goroutines that
19
+ exclusively run runtime code (such as GC workers) can quite reasonably
20
+ have no TSan events.
21
+
22
+ The addition of such a goroutine to the Go test.c is sufficient to
23
+ trigger this case, though for reliable failure (segfault) I've found it
24
+ necessary to poison the ThreadContext allocation like so:
25
+
26
+ (Example patch redacted because patch tries to apply this as a real
27
+ patch. See full commit at
28
+ https://github.com/llvm/llvm-project/commit/cdfdb06c9155080ec97d6e4f4dd90b6e7cefb0ca).
29
+
30
+ The fix is trivial: local_head should be zero-initialized.
31
+ ---
32
+ compiler-rt/lib/tsan/go/test.c | 4 ++++
33
+ compiler-rt/lib/tsan/rtl/tsan_trace.h | 2 +-
34
+ 2 files changed, 5 insertions(+), 1 deletion(-)
35
+
36
+ diff --git a/compiler-rt/lib/tsan/go/test.c b/compiler-rt/lib/tsan/go/test.c
37
+ index d328ab1b331d7..fcd396227a4ab 100644
38
+ --- a/compiler-rt/lib/tsan/go/test.c
39
+ +++ b/compiler-rt/lib/tsan/go/test.c
40
+ @@ -91,6 +91,10 @@ int main(void) {
41
+ __tsan_go_start(thr0, &thr1, (char*)&barfoo + 1);
42
+ void *thr2 = 0;
43
+ __tsan_go_start(thr0, &thr2, (char*)&barfoo + 1);
44
+ + // Goroutine that exits without a single event.
45
+ + void *thr3 = 0;
46
+ + __tsan_go_start(thr0, &thr3, (char*)&barfoo + 1);
47
+ + __tsan_go_end(thr3);
48
+ __tsan_func_exit(thr0);
49
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
50
+ __tsan_func_enter(thr1, (char*)&foobar + 1);
51
+ diff --git a/compiler-rt/lib/tsan/rtl/tsan_trace.h b/compiler-rt/lib/tsan/rtl/tsan_trace.h
52
+ index 01bb7b34f43a2..1e791ff765fec 100644
53
+ --- a/compiler-rt/lib/tsan/rtl/tsan_trace.h
54
+ +++ b/compiler-rt/lib/tsan/rtl/tsan_trace.h
55
+ @@ -190,7 +190,7 @@ struct Trace {
56
+ Mutex mtx;
57
+ IList<TraceHeader, &TraceHeader::trace_parts, TracePart> parts;
58
+ // First node non-queued into ctx->trace_part_recycle.
59
+ - TracePart* local_head;
60
+ + TracePart* local_head = nullptr;
61
+ // Final position in the last part for finished threads.
62
+ Event* final_pos = nullptr;
63
+ // Number of trace parts allocated on behalf of this trace specifically.
@@ -1375,7 +1375,11 @@ func LoadCreateSymbolicLink() error {
1375
1375
 
1376
1376
  // Readlink returns the destination of the named symbolic link.
1377
1377
  func Readlink(path string, buf []byte) (n int, err error) {
1378
- fd, err := CreateFile(StringToUTF16Ptr(path), GENERIC_READ, 0, nil, OPEN_EXISTING,
1378
+ pathp, err := UTF16PtrFromString(path)
1379
+ if err != nil {
1380
+ return -1, err
1381
+ }
1382
+ fd, err := CreateFile(pathp, GENERIC_READ, 0, nil, OPEN_EXISTING,
1379
1383
  FILE_FLAG_OPEN_REPARSE_POINT|FILE_FLAG_BACKUP_SEMANTICS, 0)
1380
1384
  if err != nil {
1381
1385
  return -1, err
@@ -6,7 +6,7 @@ golang.org/x/crypto/cryptobyte
6
6
  golang.org/x/crypto/cryptobyte/asn1
7
7
  golang.org/x/crypto/internal/alias
8
8
  golang.org/x/crypto/internal/poly1305
9
- # golang.org/x/net v0.47.1-0.20251128220604-7c360367ab7e
9
+ # golang.org/x/net v0.47.1-0.20260417193450-705de46f8788
10
10
  ## explicit; go 1.24.0
11
11
  golang.org/x/net/dns/dnsmessage
12
12
  golang.org/x/net/http/httpguts
package/bin/ttsc CHANGED
Binary file
package/bin/ttscserver CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ttsc/linux-arm",
3
- "version": "0.14.0-dev.20260529.2",
3
+ "version": "0.14.0",
4
4
  "description": "Linux arm native ttsc/ttscserver binaries and bundled Go compiler for ttsc.",
5
5
  "os": [
6
6
  "linux"