@@ -14,12 +14,14 @@ See LICENSE.TXT for details.
14
14
============================= end_copyright_notice ===========================*/
15
15
16
16
#include " clang/CodeGen/BackendUtil.h"
17
+ #include " LLVMSPIRVLib.h"
17
18
#include " clang/Basic/CodeGenOptions.h"
18
19
#include " clang/Basic/Diagnostic.h"
19
20
#include " clang/Basic/LangOptions.h"
20
21
#include " clang/Basic/TargetOptions.h"
21
22
#include " clang/Frontend/FrontendDiagnostic.h"
22
23
#include " clang/Frontend/Utils.h"
24
+ #include " clang/FrontendPasses/OptFenceLowering.h"
23
25
#include " clang/Lex/HeaderSearchOptions.h"
24
26
#include " llvm/ADT/SmallSet.h"
25
27
#include " llvm/ADT/StringExtras.h"
@@ -72,7 +74,6 @@ See LICENSE.TXT for details.
72
74
#include " llvm/Transforms/Utils/CanonicalizeAliases.h"
73
75
#include " llvm/Transforms/Utils/NameAnonGlobals.h"
74
76
#include " llvm/Transforms/Utils/SymbolRewriter.h"
75
- #include " LLVMSPIRVLib.h"
76
77
#include < memory>
77
78
#include < sstream>
78
79
using namespace clang ;
@@ -575,6 +576,7 @@ void EmitAssemblyHelper::CreatePasses(legacy::PassManager &MPM,
575
576
PMBuilder.RerollLoops = CodeGenOpts.RerollLoops ;
576
577
577
578
MPM.add (new TargetLibraryInfoWrapperPass (*TLII));
579
+ MPM.add (createOptFenceLoweringPass ());
578
580
579
581
if (TM)
580
582
TM->adjustPassManager (PMBuilder);
0 commit comments