Skip to content

Commit

Permalink
Rollup merge of #89766 - krasimirgg:llvm-14-targetregistrty, r=nagisa
Browse files Browse the repository at this point in the history
RustWrapper: adapt for an LLVM API change

No functional changes intended.

The LLVM commit
llvm/llvm-project@89b5706
moved TargetRegistry.(h|cpp) from Support to MC.
This adapts RustWrapper accordingly.
  • Loading branch information
matthiaskrgr authored Oct 19, 2021
2 parents ec724ac + e3c3f4a commit 54aa547
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 0 additions & 1 deletion compiler/rustc_llvm/llvm-wrapper/LLVMWrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
#include "llvm/Support/Host.h"
#include "llvm/Support/Memory.h"
#include "llvm/Support/SourceMgr.h"
#include "llvm/Support/TargetRegistry.h"
#include "llvm/Support/TargetSelect.h"
#include "llvm/Support/Timer.h"
#include "llvm/Support/raw_ostream.h"
Expand Down
5 changes: 5 additions & 0 deletions compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@
#include "llvm/Support/CBindingWrapping.h"
#include "llvm/Support/FileSystem.h"
#include "llvm/Support/Host.h"
#if LLVM_VERSION_LT(14, 0)
#include "llvm/Support/TargetRegistry.h"
#else
#include "llvm/MC/TargetRegistry.h"
#endif
#include "llvm/Target/TargetMachine.h"
#include "llvm/Transforms/IPO/PassManagerBuilder.h"
#include "llvm/Transforms/IPO/AlwaysInliner.h"
Expand Down

0 comments on commit 54aa547

Please sign in to comment.