]> Cypherpunks repositories - gostls13.git/commit
runtime: deduplicate syscall assembly for darwin
authorqmuntal <quimmuntal@gmail.com>
Tue, 26 Aug 2025 09:47:51 +0000 (11:47 +0200)
committerQuim Muntal <quimmuntal@gmail.com>
Mon, 15 Sep 2025 08:16:22 +0000 (01:16 -0700)
commit8320fe8f0e5283eb67429de30b4e24be6a85c7a7
treec9769641570bc4f484c6f88a10b5e27fa90062f8
parent080882a928c96f997a1cb67cef40d2cc6126ffcd
runtime: deduplicate syscall assembly for darwin

The darwin port provides different syscall functions that only
differ on how they handle the errors, and they are all written
in assembly.

This duplication can be removed by factoring out the error handling
logic to arch-agnostic Go code and leaving the assembly functions
with the only reponsibility of making the syscall and mapping
parameters between ABIs.

Updates #51087

Cq-Include-Trybots: luci.golang.try:gotip-darwin-arm64-longtest,gotip-darwin-amd64-longtest
Change-Id: I9524377f3ef9c9a638412c7e87c8f46a33ee3453
Reviewed-on: https://go-review.googlesource.com/c/go/+/699135
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Mark Freeman <markfreeman@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/runtime/sys_darwin.go
src/runtime/sys_darwin_amd64.s
src/runtime/sys_darwin_arm64.s