Set the upper limit of the number of search go routines

This commit is contained in:
Junegunn Choi 2016-08-19 01:43:38 +09:00
parent 01ee335521
commit f7f01d109e
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627
1 changed files with 1 additions and 1 deletions

View File

@ -43,7 +43,7 @@ func NewMatcher(patternBuilder func([]rune) *Pattern,
tac: tac,
eventBox: eventBox,
reqBox: util.NewEventBox(),
partitions: 16 * runtime.NumCPU(),
partitions: util.Min(8*runtime.NumCPU(), 32),
mergerCache: make(map[string]*Merger)}
}