aboutsummaryrefslogtreecommitdiff
path: root/src/pkg
diff options
context:
space:
mode:
authorDmitriy Vyukov <dvyukov@google.com>2013-08-04 23:32:40 +0400
committerDmitriy Vyukov <dvyukov@google.com>2013-08-04 23:32:40 +0400
commit49217cf5fd35e17b1e0b97a5eaad968402dc505d (patch)
tree48c9757b1a8628a2cb9b293a8b0479af0ddb7372 /src/pkg
parent0a904a3f2ed1c4c09acdb9116aa3843e5ad14dad (diff)
downloadgo-49217cf5fd35e17b1e0b97a5eaad968402dc505d.tar.xz
runtime: remove unused scheduler knob
Blockingsyscall was used in net package on windows, it's not used anymore. R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/12436043
Diffstat (limited to 'src/pkg')
-rw-r--r--src/pkg/runtime/cgocall.c15
-rw-r--r--src/pkg/runtime/runtime.h2
2 files changed, 1 insertions, 16 deletions
diff --git a/src/pkg/runtime/cgocall.c b/src/pkg/runtime/cgocall.c
index 07aef495cf..91a55131e6 100644
--- a/src/pkg/runtime/cgocall.c
+++ b/src/pkg/runtime/cgocall.c
@@ -98,15 +98,6 @@ static void unwindm(void);
static void endcgo(void);
static FuncVal endcgoV = { endcgo };
-// Gives a hint that the next syscall
-// executed by the current goroutine will block.
-// Currently used only on windows.
-void
-net·runtime_blockingSyscallHint(void)
-{
- g->blockingsyscall = true;
-}
-
void
runtime·cgocall(void (*fn)(void*), void *arg)
{
@@ -158,11 +149,7 @@ runtime·cgocall(void (*fn)(void*), void *arg)
* so it is safe to call while "in a system call", outside
* the $GOMAXPROCS accounting.
*/
- if(g->blockingsyscall) {
- g->blockingsyscall = false;
- runtime·entersyscallblock();
- } else
- runtime·entersyscall();
+ runtime·entersyscall();
runtime·asmcgocall(fn, arg);
runtime·exitsyscall();
diff --git a/src/pkg/runtime/runtime.h b/src/pkg/runtime/runtime.h
index 705845d3f1..1ecdfffcab 100644
--- a/src/pkg/runtime/runtime.h
+++ b/src/pkg/runtime/runtime.h
@@ -269,7 +269,6 @@ struct G
bool ispanic;
bool issystem; // do not output in stack dump
bool isbackground; // ignore in deadlock detector
- bool blockingsyscall; // hint that the next syscall will block
bool preempt; // preemption signal, duplicates stackguard0 = StackPreempt
int8 raceignore; // ignore race detection events
M* m; // for debuggers, but offset not hard-coded
@@ -313,7 +312,6 @@ struct M
int32 dying;
int32 profilehz;
int32 helpgc;
- bool blockingsyscall;
bool spinning;
uint32 fastrand;
uint64 ncgocall; // number of cgo calls in total