From: ankane (@ankane) <noreply+ankane@github.com>
To: pgvector/pgvector <noreply+pgvector-pgvector@github.com>
Subject: Re: [pgvector/pgvector] issue #434: Limit HNSW build's shared memory size for small tables
Date: Fri, 26 Jan 2024 21:53:14 +0000
Message-ID: <gh-pgvector-pgvector-434-c1912744489@github.com> (raw)
In-Reply-To: <gh-pgvector-pgvector-434@github.com>
References: <gh-pgvector-pgvector-434@github.com>
It should be possible to check the column storage with `TupleDescAttr(tupdesc, attnum)->attstorage`. Existing vectors could have different storages, but it's probably not a common case.
I tried using DSA in https://github.com/pgvector/pgvector/issues/409#issuecomment-1894993783 ([hnsw-fast-build-dsa branch](https://github.com/pgvector/pgvector/compare/hnsw-fast-build...hnsw-fast-build-dsa)), but `DSA_ALLOC_NO_OOM` still throws an error when running out of shared memory (at least in Docker).