From fd965c9e7ebf6c825537f24eb49b46b5e5345d5c Mon Sep 17 00:00:00 2001 From: Umar Arshad Date: Sat, 6 Aug 2016 13:25:02 -0400 Subject: [PATCH] Remove unnecessary headers --- source/binary.h | 3 ++- source/instruction.h | 3 +-- source/spirv_definition.h | 2 +- source/val/ValidationState.h | 3 +-- source/validate.h | 14 +------------- source/validate_id.cpp | 1 + 6 files changed, 7 insertions(+), 19 deletions(-) diff --git a/source/binary.h b/source/binary.h index 923a834d..0d9ef28d 100644 --- a/source/binary.h +++ b/source/binary.h @@ -28,7 +28,8 @@ #define LIBSPIRV_BINARY_H_ #include "spirv-tools/libspirv.h" -#include "table.h" +#include "spirv/1.1/spirv.h" +#include "spirv_definition.h" // Functions diff --git a/source/instruction.h b/source/instruction.h index 37b35b2a..f203dd02 100644 --- a/source/instruction.h +++ b/source/instruction.h @@ -30,10 +30,9 @@ #include #include +#include "spirv-tools/libspirv.h" #include "spirv/1.1/spirv.h" -#include "table.h" - // Describes an instruction. struct spv_instruction_t { // Normally, both opcode and extInstType contain valid data. diff --git a/source/spirv_definition.h b/source/spirv_definition.h index 59f8509f..9cd3f361 100644 --- a/source/spirv_definition.h +++ b/source/spirv_definition.h @@ -29,7 +29,7 @@ #include -#include "spirv-tools/libspirv.h" +#include "spirv/1.1/spirv.h" #define spvIsInBitfield(value, bitfield) ((value) == ((value)&bitfield)) diff --git a/source/val/ValidationState.h b/source/val/ValidationState.h index 65a3ce33..6a43c905 100644 --- a/source/val/ValidationState.h +++ b/source/val/ValidationState.h @@ -39,6 +39,7 @@ #include "spirv-tools/libspirv.h" #include "spirv/1.1/spirv.h" #include "spirv_definition.h" +#include "val/Function.h" #include "val/Id.h" namespace libspirv { @@ -61,8 +62,6 @@ enum ModuleLayoutSection { kLayoutFunctionDefinitions /// < Section 2.4 #11 }; -class Function; - /// This class manages the state of the SPIR-V validation as it is being parsed. class ValidationState_t { public: diff --git a/source/validate.h b/source/validate.h index a4d7d237..c6ffac03 100644 --- a/source/validate.h +++ b/source/validate.h @@ -27,30 +27,18 @@ #ifndef LIBSPIRV_VALIDATE_H_ #define LIBSPIRV_VALIDATE_H_ -#include -#include #include -#include -#include -#include -#include #include #include -#include "assembly_grammar.h" -#include "binary.h" -#include "diagnostic.h" #include "instruction.h" #include "spirv-tools/libspirv.h" -#include "spirv_definition.h" #include "table.h" -#include "val/BasicBlock.h" - -// Structures namespace libspirv { class ValidationState_t; +class BasicBlock; /// A function that returns a vector of BasicBlocks given a BasicBlock. Used to /// get the successor and predecessor nodes of a CFG block diff --git a/source/validate_id.cpp b/source/validate_id.cpp index 84736466..b94e8617 100644 --- a/source/validate_id.cpp +++ b/source/validate_id.cpp @@ -28,6 +28,7 @@ #include +#include #include #include #include