$ the-wire · showcase
Compiler tightens limits propagation as x509 distrust rationale lands
By RepoJournal · Filed · About Go · Composed from the cited sources · methodology
Go's compiler now folds more signed-to-unsigned range facts, the x509 distrust reasoning that was withheld during a security fix is public, and a regexp regression in Split gets reverted to its prior counting behavior.
cmd/compile: improve signed <-> unsigned limits propagation golang/go
cmd/compile now propagates limit information across signed/unsigned conversions, so range checks the compiler previously could not fold may now be eliminated. Jorropo notes the test case had to move from testdir to the ssa framework because prove would fold it first, and that the edge case is "easy to get wrong" but was kept deliberately.
crypto/x509: document reason for custom distrust golang/go
The crypto/x509 custom distrust code now carries the reasoning that was deliberately left vague in the #82345 remediation, when the notes would have tipped off exploiters about a trivially exploitable issue. Future developers reading that path get the justification the original fix had to withhold.
regexp: fix Split with a positive count and an empty first match golang/go
Split returns to counting substrings rather than stopping after n-1 matches, fixing the case where an empty match at the start of the input produced one fewer substring than requested. It also returns an empty slice again instead of nil for empty input with an empty expression, restoring what callers saw before the earlier Split change.
runtime/cgo: destroy pthread attributes after use golang/go
The cgo thread creation paths initialized a pthread attribute object per thread and never destroyed it; each is now destroyed after pthread_create returns. On OpenBSD that leaked about 50 bytes per cgo-created OS thread, which accumulates in programs that spawn threads steadily.
net: preserve IPv6 zone in Resolver.LookupNetIP golang/go
Resolver.LookupNetIP keeps the IPv6 zone on resolved addresses. Elsewhere, golang/arch's GoSyntax no longer emits R0<<$28 for constant shift counts, the form cmd/asm rejects, bringing 682 of 1084 plan9 test cases in decode.txt to re-assembly parity, up from 496.