perf: reduce lock contention#347
Conversation
|
What is vector_tapes? It should be a hidden config named like |
It's an experimental trick to speed parallel build, and won't be merged as-is. |
|
With
|
fd3da73 to
dc53de2
Compare
vector_tapes to reduce lock contentiondegree_of_parallelism to reduce lock contention
It's renamed to Its default is |
|
Is there any downside to have degree_of_parallelism as 32? Shall we prefix it with |
I don't think so.
I don't think it's necessary. |
|
This feature modified the layout of storage, so it should be in |
|
To be noticed, the 8w build time is slower than before, from 2400s -> 3100s .
|
69c6415 to
8401732
Compare
degree_of_parallelism to reduce lock contentiondegree_of_parallelism and pin_level
fcbbd9a to
7d7b0e5
Compare
degree_of_parallelism and pin_leveldegree_of_parallelism and more levels to pin
1aeae77 to
b865fc4
Compare
degree_of_parallelism and more levels to pinSigned-off-by: usamoi <usamoi@outlook.com>
```sql create index on laion1m768_train using vchordrq (embedding vector_ip_ops) with (options = $$ build.pin = 2 build.internal.lists = [256, 4096] build.internal.build_threads = 20 build.internal.spherical_centroids = true degree_of_parallelism = 40 $$); ``` `degree_of_parallelism` is 32 by default. It reduces lock contention during insertion, especially, in a build where `lists.len() != 1`. `build.pin` is `-1` by default. `build.pin = 2` caches almost everything in memory, which speeds build but spends more memory. `build.pin = false` and `build.pin = true` still works, and they're mapped to `build.pin = -1` and `build.pin = 1`. Signed-off-by: usamoi <usamoi@outlook.com>
degree_of_parallelismis 32 by default. It reduces lock contention during insertion, especially, in a build wherelists.len() != 1.build.pinis-1by default.build.pin = 2caches almost everything in memory, which speeds build but spends more memory.build.pin = falseandbuild.pin = truestill works, and they're mapped tobuild.pin = -1andbuild.pin = 1.