Skip to content

Commit 3e313e4

Browse files
ddrcodermeta-codesync[bot]
authored andcommitted
SIMDConfig::has_dynamic_dispatch() (#5460)
Summary: Pull Request resolved: #5460 Reviewed By: pankajsingh88, mnorris11 Differential Revision: D110967632 fbshipit-source-id: a385274e27a36b45ee46638d502fd2086d863016
1 parent af45a3b commit 3e313e4

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

faiss/utils/simd_levels.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,14 @@ struct FAISS_API SIMDConfig {
163163

164164
static SIMDLevel auto_detect_simd_level();
165165

166+
static constexpr bool has_dynamic_dispatch() {
167+
#ifdef FAISS_ENABLE_DD
168+
return true;
169+
#else
170+
return false;
171+
#endif
172+
}
173+
166174
SIMDConfig(const char** faiss_simd_level_env = nullptr);
167175

168176
/// Set the SIMD level. Throws FaissException if level is not supported.

0 commit comments

Comments
 (0)