[igt-dev] [PATCH i-g-t 02/14] assembler: Remove unused headers

Ryszard Knop ryszard.knop at intel.com
Tue May 31 14:28:32 UTC 2022


Using CLion's automated code inspection, most unused includes were found
and removed. Some warnings remain as CLion is unable to track code usage
across certain attributes, but the vast majority of unneeded headers are
now gone.

Signed-off-by: Ryszard Knop <ryszard.knop at intel.com>
---
 assembler/brw_disasm.c  | 3 ---
 assembler/brw_eu_util.c | 1 -
 assembler/disasm-main.c | 1 -
 assembler/gen8_disasm.c | 3 ---
 4 files changed, 8 deletions(-)

diff --git a/assembler/brw_disasm.c b/assembler/brw_disasm.c
index 4dec829f..a804c655 100644
--- a/assembler/brw_disasm.c
+++ b/assembler/brw_disasm.c
@@ -21,10 +21,7 @@
  */
 
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
-#include <getopt.h>
-#include <unistd.h>
 #include <stdarg.h>
 
 #include "brw_compat.h"
diff --git a/assembler/brw_eu_util.c b/assembler/brw_eu_util.c
index f9126abf..2014b093 100644
--- a/assembler/brw_eu_util.c
+++ b/assembler/brw_eu_util.c
@@ -30,7 +30,6 @@
   */
 
 
-#include "brw_context.h"
 #include "brw_defines.h"
 #include "brw_eu.h"
 
diff --git a/assembler/disasm-main.c b/assembler/disasm-main.c
index b3655568..a5969bbb 100644
--- a/assembler/disasm-main.c
+++ b/assembler/disasm-main.c
@@ -24,7 +24,6 @@
 #include <stdlib.h>
 #include <string.h>
 #include <getopt.h>
-#include <unistd.h>
 
 #include "gen4asm.h"
 #include "brw_eu.h"
diff --git a/assembler/gen8_disasm.c b/assembler/gen8_disasm.c
index 99b062ea..8ffe947a 100644
--- a/assembler/gen8_disasm.c
+++ b/assembler/gen8_disasm.c
@@ -21,10 +21,7 @@
  */
 
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
-#include <getopt.h>
-#include <unistd.h>
 #include <stdarg.h>
 
 #include "brw_context.h"
-- 
2.36.1



More information about the igt-dev mailing list