forked from OSchip/llvm-project
Update PTX generator to latest LLVM changes
llvm-svn: 231652
This commit is contained in:
parent
05b098d250
commit
ed61e1fcd1
|
@ -142,6 +142,7 @@ if (BUILD_SHARED_LIBS)
|
||||||
LLVMTransformUtils
|
LLVMTransformUtils
|
||||||
LLVMAnalysis
|
LLVMAnalysis
|
||||||
LLVMipo
|
LLVMipo
|
||||||
|
LLVMMC
|
||||||
)
|
)
|
||||||
link_directories(
|
link_directories(
|
||||||
${LLVM_LIBRARY_DIR}
|
${LLVM_LIBRARY_DIR}
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
#include "llvm/IR/LegacyPassManager.h"
|
#include "llvm/IR/LegacyPassManager.h"
|
||||||
#include "llvm/ADT/SetVector.h"
|
#include "llvm/ADT/SetVector.h"
|
||||||
#include "llvm/Analysis/TargetLibraryInfo.h"
|
#include "llvm/Analysis/TargetLibraryInfo.h"
|
||||||
|
#include "llvm/Analysis/TargetTransformInfo.h"
|
||||||
#include "llvm/Support/Debug.h"
|
#include "llvm/Support/Debug.h"
|
||||||
#include "llvm/Support/FormattedStream.h"
|
#include "llvm/Support/FormattedStream.h"
|
||||||
#include "llvm/Support/TargetRegistry.h"
|
#include "llvm/Support/TargetRegistry.h"
|
||||||
|
@ -559,11 +560,10 @@ static bool createASMAsString(Module *New, const StringRef &Triple,
|
||||||
TargetMachine &Target = *target.get();
|
TargetMachine &Target = *target.get();
|
||||||
|
|
||||||
// Build up all of the passes that we want to do to the module.
|
// Build up all of the passes that we want to do to the module.
|
||||||
PassManager PM;
|
llvm::legacy::PassManager PM;
|
||||||
|
|
||||||
PM.add(new TargetLibraryInfoWrapperPass(TheTriple));
|
PM.add(new TargetLibraryInfoWrapperPass(TheTriple));
|
||||||
PM.add(new DataLayoutPass(*Target.getDataLayout()));
|
PM.add(createTargetTransformInfoWrapperPass(Target.getTargetIRAnalysis()));
|
||||||
Target.addAnalysisPasses(PM);
|
|
||||||
|
|
||||||
{
|
{
|
||||||
raw_string_ostream NameROS(ASM);
|
raw_string_ostream NameROS(ASM);
|
||||||
|
|
Loading…
Reference in New Issue