Skip to content

Sync/gh go1.26 with upstream#1

Merged
dgilarranz-ik merged 0 commit into
release-branch.go1.27from
sync/gh-go1.26-with-upstream
Jul 21, 2026
Merged

Sync/gh go1.26 with upstream#1
dgilarranz-ik merged 0 commit into
release-branch.go1.27from
sync/gh-go1.26-with-upstream

Conversation

@haritzsaiz

Copy link
Copy Markdown

This pull request introduces several important runtime, os, and syscall improvements and bug fixes, as well as test coverage for recent changes. The most significant updates include ensuring that all directory changes via (*File).Chdir are properly logged for test caching, improving error handling and context propagation in signal handling, and fixing a runtime memory allocation bug. Additional changes enhance syscall safety after process forks and clarify documentation.

Testlog integration and working directory tracking:

  • Added calls to testlog.Logger().Chdir in (*File).Chdir on both POSIX and Plan 9 systems to ensure all working directory changes are recorded for the Go test cache, and added a new test TestFileChdirTestlog to verify this behavior (src/os/file_posix.go, src/os/file_plan9.go, src/os/os_test.go). [1] [2] [3] [4] [5]

Signal handling and context improvements:

  • Implemented the Is method for signalError to allow it to be compared with context.Canceled, and added a test to check that NotifyContext propagates the correct cause (src/os/signal/signal.go, src/os/signal/signal_test.go). [1] [2]

Runtime and memory management fixes:

  • Fixed a bug in moveSliceNoCap to correctly calculate and return the new slice capacity, preventing incorrect memory handling (src/runtime/slice.go).
  • Added a new regression test test/fixedbugs/issue80004.go to check for pointer bitmask errors in memory allocation that could cause the garbage collector to misinterpret non-pointer fields as pointers.

Syscall safety and documentation:

  • Annotated several syscall-related functions on Darwin with //go:norace to prevent race instrumentation after fork or in signal handlers, and clarified the documentation about stack growth and pointer safety (src/syscall/exec_libc2.go, src/syscall/syscall_darwin.go). [1] [2] [3] [4] [5] [6] [7] [8]

Other changes:

  • Minor updates to go version declarations in test data for module and script files (src/cmd/go/testdata/mod/example.com_importcrypto_v1.0.0.txt, src/cmd/go/testdata/script/mod_get_fips140_issue73649.txt). [1] [2]
  • Updated CPU feature checks for AVX512 instructions in garbage collector scan logic (src/internal/runtime/gc/scan/scan_amd64.go).

@haritzsaiz
haritzsaiz changed the base branch from release-branch.go1.26 to release-branch.go1.27 July 15, 2026 09:34
@dgilarranz-ik
dgilarranz-ik merged commit 5e3b693 into release-branch.go1.27 Jul 21, 2026
2 of 3 checks passed
@dgilarranz-ik
dgilarranz-ik force-pushed the release-branch.go1.27 branch from 08afb68 to aec3277 Compare July 21, 2026 07:28
@haritzsaiz
haritzsaiz deleted the sync/gh-go1.26-with-upstream branch July 22, 2026 06:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants