diff --git a/CMakeLists.txt b/CMakeLists.txt index fbfd1bcf..42ed2c4a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -301,6 +301,7 @@ if (BUILD_CXX_LANGUAGE_PACKAGE) msp430asmparser msp430codegen nvptxcodegen powerpcasmparser powerpccodegen + riscvasmparser riscvcodegen sparcasmparser sparccodegen systemzasmparser systemzcodegen webassemblyasmparser webassemblycodegen diff --git a/src/lib_cxx/data/parser/cxx/ClangInvocationInfo.cpp b/src/lib_cxx/data/parser/cxx/ClangInvocationInfo.cpp index 8223c4a2..d92eb91e 100644 --- a/src/lib_cxx/data/parser/cxx/ClangInvocationInfo.cpp +++ b/src/lib_cxx/data/parser/cxx/ClangInvocationInfo.cpp @@ -61,7 +61,7 @@ ClangInvocationInfo ClangInvocationInfo::getClangInvocationString( new clang::FileManager(clang::FileSystemOptions())); const std::unique_ptr Driver( - newDriver(&Diagnostics, BinaryName, Files->getVirtualFileSystem())); + newDriver(&Diagnostics, BinaryName, &Files->getVirtualFileSystem())); // Since the input might only be virtual, don't check whether it exists. Driver->setCheckInputsExist(false); const std::unique_ptr Compilation( diff --git a/src/lib_cxx/data/parser/cxx/GeneratePCHAction.cpp b/src/lib_cxx/data/parser/cxx/GeneratePCHAction.cpp index 603e7eff..972f3f69 100644 --- a/src/lib_cxx/data/parser/cxx/GeneratePCHAction.cpp +++ b/src/lib_cxx/data/parser/cxx/GeneratePCHAction.cpp @@ -3,6 +3,7 @@ #include #include #include +#include #include "PreprocessorCallbacks.h" @@ -36,14 +37,16 @@ std::unique_ptr GeneratePCHAction::CreateASTConsumer( const auto& FrontendOpts = CI.getFrontendOpts(); auto Buffer = std::make_shared(); std::vector> Consumers; - Consumers.push_back(llvm::make_unique( + Consumers.push_back(std::make_unique( CI.getPreprocessor(), + CI.getModuleCache(), OutputFile, Sysroot, Buffer, FrontendOpts.ModuleFileExtensions, - true, - FrontendOpts.IncludeTimestamps)); + true, // always allow errors in the PCH + FrontendOpts.IncludeTimestamps, + +CI.getLangOpts().CacheGeneratedPCH)); Consumers.push_back(CI.getPCHContainerWriter().CreatePCHContainerGenerator( CI, InFile, OutputFile, std::move(OS), Buffer));