summaryrefslogtreecommitdiff
path: root/src/constants.go
diff options
context:
space:
mode:
authorJunegunn Choi <junegunn.c@gmail.com>2016-09-07 09:58:18 +0900
committerJunegunn Choi <junegunn.c@gmail.com>2016-09-18 14:34:46 +0900
commit2fc7c18747250ebf8adf68d2057ec22af6976f29 (patch)
treeaab013c4492a82dd613866a35b98fc9de42f533d /src/constants.go
parent8ef2420677abf5cca27b47bead6e70e42220c7aa (diff)
downloadfzf-2fc7c18747250ebf8adf68d2057ec22af6976f29.tar.gz
Revise ranking algorithm
Diffstat (limited to 'src/constants.go')
-rw-r--r--src/constants.go10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/constants.go b/src/constants.go
index c0410863..04b10903 100644
--- a/src/constants.go
+++ b/src/constants.go
@@ -8,7 +8,7 @@ import (
const (
// Current version
- version = "0.13.5"
+ version = "0.15.0"
// Core
coordinatorDelayMax time.Duration = 100 * time.Millisecond
@@ -24,11 +24,17 @@ const (
spinnerDuration = 200 * time.Millisecond
// Matcher
- progressMinDuration = 200 * time.Millisecond
+ numPartitionsMultiplier = 8
+ maxPartitions = 32
+ progressMinDuration = 200 * time.Millisecond
// Capacity of each chunk
chunkSize int = 100
+ // Pre-allocated memory slices to minimize GC
+ slab16Size int = 100 * 1024 // 200KB * 32 = 12.8MB
+ slab32Size int = 2048 // 8KB * 32 = 256KB
+
// Do not cache results of low selectivity queries
queryCacheMax int = chunkSize / 5