From 58e3ae2fae7dcb22a67ba802c250ba0abf894b1d Mon Sep 17 00:00:00 2001 From: Matthew Dempsky Date: Wed, 21 Oct 2015 12:48:53 -0700 Subject: runtime: split plan9 and solaris's m fields into new embedded mOS type Reduces the size of m by ~8% on linux/amd64 (1040 bytes -> 960 bytes). There are also windows-specific fields, but they're currently referenced in OS-independent source files (but only when GOOS=="windows"). Change-Id: I13e1471ff585ccced1271f74209f8ed6df14c202 Reviewed-on: https://go-review.googlesource.com/16173 Run-TryBot: Matthew Dempsky TryBot-Result: Gobot Gobot Reviewed-by: Ian Lance Taylor --- src/runtime/runtime2.go | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) (limited to 'src/runtime/runtime2.go') diff --git a/src/runtime/runtime2.go b/src/runtime/runtime2.go index d4e3758678..7d6c441ef5 100644 --- a/src/runtime/runtime2.go +++ b/src/runtime/runtime2.go @@ -269,15 +269,6 @@ type g struct { gcAssistBytes int64 } -type mts struct { - tv_sec int64 - tv_nsec int64 -} - -type mscratch struct { - v [6]uintptr -} - type m struct { g0 *g // goroutine with scheduling stack morebuf gobuf // gobuf arg to morestack @@ -343,18 +334,7 @@ type m struct { libcallg guintptr syscall libcall // stores syscall parameters on windows //#endif - //#ifdef GOOS_solaris - perrno *int32 // pointer to tls errno - // these are here because they are too large to be on the stack - // of low-level NOSPLIT functions. - //LibCall libcall; - ts mts - scratch mscratch - //#endif - //#ifdef GOOS_plan9 - notesig *int8 - errstr *byte - //#endif + mOS } type p struct { -- cgit v1.3-5-g9baa