Disable clang-tidy for large/generated files.
* They are too big to run with clang-tidy, even without the
clang-analyzer-* checks.
* Use the new tidy_disabled_srcs to disable clang-tidy for
only the listed source files.
Test: WITH_TIDY=1 TIDY_TIMEOUT=90 make tidy-packages-modules-NeuralNetworks
Bug: 198712638
Bug: 198098397
Change-Id: I2549d840480e33d4a5da597813f63be51290c8bb
diff --git a/common/Android.bp b/common/Android.bp
index b02e500..a972625 100644
--- a/common/Android.bp
+++ b/common/Android.bp
@@ -24,6 +24,23 @@
export_include_dirs: ["include"],
}
+// The following files took too much time to compile with clang-tidy.
+tidy_disabled_common_operations_files = [
+ "operations/Activation.cpp",
+ "operations/Broadcast.cpp",
+ "operations/Concatenation.cpp",
+ "operations/Conv2D.cpp",
+ "operations/FullyConnected.cpp",
+ "operations/L2Normalization.cpp",
+ "operations/LocalResponseNormalization.cpp",
+ "operations/Pooling.cpp",
+ "operations/PRelu.cpp",
+ "operations/Reshape.cpp",
+ "operations/SimpleMath.cpp",
+ "operations/Softmax.cpp",
+ "operations/Transpose.cpp",
+]
+
cc_defaults {
name: "neuralnetworks_operations",
host_supported: true,
@@ -73,6 +90,7 @@
"operations/UnidirectionalSequenceLSTM.cpp",
"operations/UnidirectionalSequenceRNN.cpp",
],
+ tidy_disabled_srcs: tidy_disabled_common_operations_files,
}
cc_library_static {