From 67d894ea64bc52245abf3f2ba89122a749d99c53 Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Thu, 13 Aug 2009 19:38:51 +0000 Subject: TargetRegistry: Reorganize AsmPrinter construction so that clients pass in the TargetAsmInfo. This eliminates a dependency on TargetMachine.h from TargetRegistry.h, which technically was a layering violation. - Clients probably can only sensibly pass in the same TargetAsmInfo as the TargetMachine has, but there are only limited clients of this API. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78928 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/LLVMTargetMachine.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/CodeGen/LLVMTargetMachine.cpp') diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp index 71efa1375e..cafe4d3f14 100644 --- a/lib/CodeGen/LLVMTargetMachine.cpp +++ b/lib/CodeGen/LLVMTargetMachine.cpp @@ -106,7 +106,8 @@ bool LLVMTargetMachine::addAssemblyEmitter(PassManagerBase &PM, CodeGenOpt::Level OptLevel, bool Verbose, formatted_raw_ostream &Out) { - FunctionPass *Printer = getTarget().createAsmPrinter(Out, *this, Verbose); + FunctionPass *Printer = + getTarget().createAsmPrinter(Out, *this, getTargetAsmInfo(), Verbose); if (!Printer) return true; -- cgit v1.2.3-70-g09d2