Explicitly set default cpu number to 1
This commit is contained in:
@ -87,6 +87,8 @@ func setupClientEnv(config *testpb.ClientConfig) {
|
||||
// TODO: change default number of cores used if 1 is not fastest.
|
||||
if config.CoreLimit > 1 {
|
||||
runtime.GOMAXPROCS(int(config.CoreLimit))
|
||||
} else {
|
||||
runtime.GOMAXPROCS(1)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -85,8 +85,8 @@ func startBenchmarkServer(config *testpb.ServerConfig, serverPort int) (*benchma
|
||||
numOfCores := 1
|
||||
if config.CoreLimit > 1 {
|
||||
numOfCores = int(config.CoreLimit)
|
||||
runtime.GOMAXPROCS(numOfCores)
|
||||
}
|
||||
runtime.GOMAXPROCS(numOfCores)
|
||||
|
||||
var opts []grpc.ServerOption
|
||||
|
||||
|
Reference in New Issue
Block a user