Skip to content

Commit 669bf98

Browse files
Racer Engineerfacebook-github-bot
authored andcommitted
Remove unused headers from AutoTune.cpp and clone_index.cpp (#4513)
Summary: ## Instructions about RACER Diffs: **This diff was generated by Racer AI agent on behalf of [Junjie Qi](https://www.internalfb.com/profile/view/100004163713284) for T233050949. If the diff quality is poor, consider contacting the user to provide clearer instructions on the task.** - If you are happy with the changes, commandeer it if minor edits are needed. (**we encourage commandeer to get the diff credit**) - If you are not happy with the changes, please comment on the diff with clear actions and send it back to the author. Racer will pick it up and re-generate. - If you really feel the Racer is not helping with this change (alas, some complex changes are hard for AI) feel free to abandon this diff. ## Summary: This diff removes unused headers from two faiss files: **AutoTune.cpp:** - Removed unused `#include <cmath>` header - Analysis confirmed no mathematical functions (sqrt, pow, ceil, etc.) are used in the file **clone_index.cpp:** - Removed unused `#include <cstdio>` header (no printf/fprintf calls) - Removed unused `#include <cstdlib>` header (no abort/exit/malloc calls) - Kept `#include <faiss/impl/FaissAssert.h>` which is used extensively These changes reduce compilation overhead and dependencies without affecting functionality. --- > Generated by [RACER](https://www.internalfb.com/wiki/RACER_(Risk-Aware_Code_Editing_and_Refactoring)/), powered by [Confucius](https://www.internalfb.com/wiki/Confucius/Analect/Shared_Analects/Confucius_Code_Assist_(CCA)/) [Session](https://www.internalfb.com/confucius?session_id=42df7f2e-7356-11f0-9ffa-ae7e0719de25&tab=Chat), [Trace](https://www.internalfb.com/confucius?session_id=42df7f2e-7356-11f0-9ffa-ae7e0719de25&tab=Trace) Differential Revision: D79785715
1 parent 8482842 commit 669bf98

2 files changed

Lines changed: 0 additions & 4 deletions

File tree

faiss/AutoTune.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#include <faiss/AutoTune.h>
1515

1616
#include <cinttypes>
17-
#include <cmath>
1817

1918
#include <faiss/impl/FaissAssert.h>
2019
#include <faiss/utils/random.h>

faiss/clone_index.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99

1010
#include <faiss/clone_index.h>
1111

12-
#include <cstdio>
13-
#include <cstdlib>
14-
1512
#include <faiss/impl/FaissAssert.h>
1613

1714
#include <faiss/Index2Layer.h>

0 commit comments

Comments
 (0)