removed unnecessary GOMAXPROCS function calls
This commit is contained in:
parent
ff59bbc14a
commit
42782bba18
5 changed files with 1 additions and 15 deletions
|
@ -6,7 +6,6 @@ package blockchain
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"runtime"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/btcsuite/btcd/txscript"
|
"github.com/btcsuite/btcd/txscript"
|
||||||
|
@ -15,8 +14,6 @@ import (
|
||||||
// TestCheckBlockScripts ensures that validating the all of the scripts in a
|
// TestCheckBlockScripts ensures that validating the all of the scripts in a
|
||||||
// known-good block doesn't return an error.
|
// known-good block doesn't return an error.
|
||||||
func TestCheckBlockScripts(t *testing.T) {
|
func TestCheckBlockScripts(t *testing.T) {
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
|
|
||||||
testBlockNum := 277647
|
testBlockNum := 277647
|
||||||
blockDataFile := fmt.Sprintf("%d.dat.bz2", testBlockNum)
|
blockDataFile := fmt.Sprintf("%d.dat.bz2", testBlockNum)
|
||||||
blocks, err := loadBlocks(blockDataFile)
|
blocks, err := loadBlocks(blockDataFile)
|
||||||
|
|
3
btcd.go
3
btcd.go
|
@ -297,9 +297,6 @@ func loadBlockDB() (database.DB, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
// Use all processor cores.
|
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
|
|
||||||
// Block and transaction processing can cause bursty allocations. This
|
// Block and transaction processing can cause bursty allocations. This
|
||||||
// limits the garbage collector from excessively overallocating during
|
// limits the garbage collector from excessively overallocating during
|
||||||
// bursts. This value was arrived at with the help of profiling live
|
// bursts. This value was arrived at with the help of profiling live
|
||||||
|
|
|
@ -7,7 +7,6 @@ package main
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"runtime"
|
|
||||||
|
|
||||||
"github.com/btcsuite/btcd/blockchain"
|
"github.com/btcsuite/btcd/blockchain"
|
||||||
"github.com/btcsuite/btcd/blockchain/indexers"
|
"github.com/btcsuite/btcd/blockchain/indexers"
|
||||||
|
@ -119,8 +118,7 @@ func realMain() error {
|
||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
// Use all processor cores and up some limits.
|
// up some limits.
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
if err := limits.SetLimits(); err != nil {
|
if err := limits.SetLimits(); err != nil {
|
||||||
os.Exit(1)
|
os.Exit(1)
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,7 +7,6 @@ package main
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"runtime"
|
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/btcsuite/btcd/database"
|
"github.com/btcsuite/btcd/database"
|
||||||
|
@ -106,9 +105,6 @@ func realMain() error {
|
||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
// Use all processor cores.
|
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
|
|
||||||
// Work around defer not working after os.Exit()
|
// Work around defer not working after os.Exit()
|
||||||
if err := realMain(); err != nil {
|
if err := realMain(); err != nil {
|
||||||
os.Exit(1)
|
os.Exit(1)
|
||||||
|
|
|
@ -9,7 +9,6 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"reflect"
|
"reflect"
|
||||||
"runtime"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/btcsuite/btcd/chaincfg"
|
"github.com/btcsuite/btcd/chaincfg"
|
||||||
|
@ -278,7 +277,6 @@ func TestInterface(t *testing.T) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Run all of the interface tests against the database.
|
// Run all of the interface tests against the database.
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
|
|
||||||
// Change the maximum file size to a small value to force multiple flat
|
// Change the maximum file size to a small value to force multiple flat
|
||||||
// files with the test data set.
|
// files with the test data set.
|
||||||
|
|
Loading…
Reference in a new issue