Browse Source

[spirv] Cleanup old included headers. (#1945)

Ehsan 6 years ago
parent
commit
02d5c92400

+ 0 - 1
tools/clang/include/clang/SPIRV/SpirvBuilder.h

@@ -15,7 +15,6 @@
 #include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "clang/SPIRV/SpirvModule.h"
 #include "clang/SPIRV/SpirvModule.h"
-#include "llvm/ADT/MapVector.h"
 
 
 namespace clang {
 namespace clang {
 namespace spirv {
 namespace spirv {

+ 0 - 1
tools/clang/include/clang/SPIRV/SpirvContext.h

@@ -10,7 +10,6 @@
 #define LLVM_CLANG_SPIRV_SPIRVCONTEXT_H
 #define LLVM_CLANG_SPIRV_SPIRVCONTEXT_H
 
 
 #include <array>
 #include <array>
-#include <unordered_map>
 
 
 #include "dxc/DXIL/DxilShaderModel.h"
 #include "dxc/DXIL/DxilShaderModel.h"
 #include "clang/Frontend/FrontendAction.h"
 #include "clang/Frontend/FrontendAction.h"

+ 1 - 1
tools/clang/include/clang/SPIRV/SpirvFunction.h

@@ -11,7 +11,6 @@
 
 
 #include <vector>
 #include <vector>
 
 
-#include "clang/SPIRV/SpirvBasicBlock.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "llvm/ADT/ArrayRef.h"
 #include "llvm/ADT/ArrayRef.h"
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/ADT/SmallVector.h"
@@ -19,6 +18,7 @@
 namespace clang {
 namespace clang {
 namespace spirv {
 namespace spirv {
 
 
+class SpirvBasicBlock;
 class SpirvVisitor;
 class SpirvVisitor;
 
 
 /// The class representing a SPIR-V function in memory.
 /// The class representing a SPIR-V function in memory.

+ 1 - 1
tools/clang/include/clang/SPIRV/SpirvModule.h

@@ -11,7 +11,6 @@
 
 
 #include <vector>
 #include <vector>
 
 
-#include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "llvm/ADT/SetVector.h"
 #include "llvm/ADT/SetVector.h"
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/ADT/SmallVector.h"
@@ -19,6 +18,7 @@
 namespace clang {
 namespace clang {
 namespace spirv {
 namespace spirv {
 
 
+class SpirvFunction;
 class SpirvVisitor;
 class SpirvVisitor;
 
 
 /// The class representing a SPIR-V module in memory.
 /// The class representing a SPIR-V module in memory.

+ 0 - 3
tools/clang/lib/SPIRV/DeclResultIdMapper.cpp

@@ -9,10 +9,7 @@
 
 
 #include "DeclResultIdMapper.h"
 #include "DeclResultIdMapper.h"
 
 
-#include <algorithm>
-#include <cstring>
 #include <sstream>
 #include <sstream>
-#include <unordered_map>
 
 
 #include "dxc/DXIL/DxilConstants.h"
 #include "dxc/DXIL/DxilConstants.h"
 #include "dxc/DXIL/DxilTypeSystem.h"
 #include "dxc/DXIL/DxilTypeSystem.h"

+ 1 - 3
tools/clang/lib/SPIRV/EmitVisitor.cpp

@@ -10,10 +10,8 @@
 #include "EmitVisitor.h"
 #include "EmitVisitor.h"
 #include "clang/SPIRV/BitwiseCast.h"
 #include "clang/SPIRV/BitwiseCast.h"
 #include "clang/SPIRV/SpirvBasicBlock.h"
 #include "clang/SPIRV/SpirvBasicBlock.h"
-#include "clang/SPIRV/SpirvBuilder.h"
 #include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
 #include "clang/SPIRV/SpirvInstruction.h"
-#include "clang/SPIRV/SpirvModule.h"
 #include "clang/SPIRV/SpirvType.h"
 #include "clang/SPIRV/SpirvType.h"
 #include "clang/SPIRV/String.h"
 #include "clang/SPIRV/String.h"
 
 
@@ -178,7 +176,7 @@ void EmitVisitor::encodeString(llvm::StringRef value) {
   curInst.insert(curInst.end(), words.begin(), words.end());
   curInst.insert(curInst.end(), words.begin(), words.end());
 }
 }
 
 
-bool EmitVisitor::visit(SpirvModule *m, Phase phase) {
+bool EmitVisitor::visit(SpirvModule *, Phase) {
   // No pre-visit operations needed for SpirvModule.
   // No pre-visit operations needed for SpirvModule.
   return true;
   return true;
 }
 }

+ 1 - 1
tools/clang/lib/SPIRV/LiteralTypeVisitor.cpp

@@ -9,7 +9,7 @@
 
 
 #include "LiteralTypeVisitor.h"
 #include "LiteralTypeVisitor.h"
 #include "clang/SPIRV/AstTypeProbe.h"
 #include "clang/SPIRV/AstTypeProbe.h"
-#include "clang/SPIRV/SpirvBuilder.h"
+#include "clang/SPIRV/SpirvFunction.h"
 
 
 namespace clang {
 namespace clang {
 namespace spirv {
 namespace spirv {

+ 0 - 2
tools/clang/lib/SPIRV/LiteralTypeVisitor.h

@@ -16,8 +16,6 @@
 namespace clang {
 namespace clang {
 namespace spirv {
 namespace spirv {
 
 
-class SpirvBuilder;
-
 class LiteralTypeVisitor : public Visitor {
 class LiteralTypeVisitor : public Visitor {
 public:
 public:
   LiteralTypeVisitor(const ASTContext &ctx, SpirvContext &spvCtx,
   LiteralTypeVisitor(const ASTContext &ctx, SpirvContext &spvCtx,

+ 1 - 0
tools/clang/lib/SPIRV/SpirvFunction.cpp

@@ -9,6 +9,7 @@
 
 
 #include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvFunction.h"
 #include "BlockReadableOrder.h"
 #include "BlockReadableOrder.h"
+#include "clang/SPIRV/SpirvBasicBlock.h"
 #include "clang/SPIRV/SpirvVisitor.h"
 #include "clang/SPIRV/SpirvVisitor.h"
 
 
 namespace clang {
 namespace clang {

+ 1 - 0
tools/clang/lib/SPIRV/SpirvModule.cpp

@@ -8,6 +8,7 @@
 //===----------------------------------------------------------------------===//
 //===----------------------------------------------------------------------===//
 
 
 #include "clang/SPIRV/SpirvModule.h"
 #include "clang/SPIRV/SpirvModule.h"
+#include "clang/SPIRV/SpirvFunction.h"
 #include "clang/SPIRV/SpirvVisitor.h"
 #include "clang/SPIRV/SpirvVisitor.h"
 
 
 namespace clang {
 namespace clang {