This file should always have included MCAssembler and not MCStreamer. NFC
[oota-llvm.git] / unittests / Analysis / MixedTBAATest.cpp
index 2cf7c734dc657006ed29c37961975c2e4519a4e1..7b8a25c4438928eea8956a8ca7fb21a7d0d98a6b 100644 (file)
@@ -13,7 +13,7 @@
 #include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/MDBuilder.h"
 #include "llvm/IR/Module.h"
-#include "llvm/PassManager.h"
+#include "llvm/IR/LegacyPassManager.h"
 #include "llvm/Support/CommandLine.h"
 #include "gtest/gtest.h"
 
@@ -27,7 +27,7 @@ protected:
   LLVMContext C;
   Module M;
   MDBuilder MD;
-  PassManager PM;
+  legacy::PassManager PM;
 };
 
 TEST_F(MixedTBAATest, MixedTBAA) {
@@ -43,7 +43,7 @@ TEST_F(MixedTBAATest, MixedTBAA) {
 
   auto *Store1 = new StoreInst(Value, Addr, BB);
   auto *Store2 = new StoreInst(Value, Addr, BB);
-  ReturnInst::Create(C, 0, BB);
+  ReturnInst::Create(C, nullptr, BB);
 
   // New TBAA metadata
   {
@@ -65,7 +65,7 @@ TEST_F(MixedTBAATest, MixedTBAA) {
   // Run the TBAA eval pass on a mixture of path-aware and non-path-aware TBAA.
   // The order of the metadata (path-aware vs non-path-aware) is important,
   // because the AA eval pass only runs one test per store-pair.
-  const char* args[] = { "MixedTBAATest", "-evaluate-tbaa" };
+  const char* args[] = { "MixedTBAATest", "-evaluate-aa-metadata" };
   cl::ParseCommandLineOptions(sizeof(args) / sizeof(const char*), args);
   PM.add(createTypeBasedAliasAnalysisPass());
   PM.add(createAAEvalPass());