Skip to content

Commit 6da9952

Browse files
JAicewizardfacebook-github-bot
authored andcommitted
Add explicit instanciations of search_dispatch_implem (#3860)
Summary: Since commit 32f0e8c (#3190) faiss fails to build on gcc7. For some reason gcc7 needs these explicit instanciations (or rather, for some reason later versions are OK without them). This commit partially revers that commit, adding back the explicit instanciations. Pull Request resolved: #3860 Reviewed By: mengdilin Differential Revision: D62762224 Pulled By: mnorris11 fbshipit-source-id: 938d5bc1917ef947847b1d8fcc3e40cea52e8367
1 parent f67f518 commit 6da9952

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

faiss/IndexFastScan.cpp

+16
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,22 @@ void IndexFastScan::search_implem_14(
549549
}
550550
}
551551

552+
template void IndexFastScan::search_dispatch_implem<true>(
553+
idx_t n,
554+
const float* x,
555+
idx_t k,
556+
float* distances,
557+
idx_t* labels,
558+
const NormTableScaler* scaler) const;
559+
560+
template void IndexFastScan::search_dispatch_implem<false>(
561+
idx_t n,
562+
const float* x,
563+
idx_t k,
564+
float* distances,
565+
idx_t* labels,
566+
const NormTableScaler* scaler) const;
567+
552568
void IndexFastScan::reconstruct(idx_t key, float* recons) const {
553569
std::vector<uint8_t> code(code_size, 0);
554570
BitstringWriter bsw(code.data(), code_size);

0 commit comments

Comments
 (0)