diff options
author | Matt Fleming <matt@console-pimps.org> | 2010-05-21 12:54:43 +0000 |
---|---|---|
committer | Matt Fleming <matt@console-pimps.org> | 2010-05-21 12:54:43 +0000 |
commit | d8a33ddcfeb29e7ec792b14be946a05ab998a38e (patch) | |
tree | 3df382a47fe6a3348c51b628926dfbb6d5c72b69 /tools/llvm-mc | |
parent | 7efaef6b822089349b44f15392e0da73a05ebb0a (diff) | |
download | external_llvm-d8a33ddcfeb29e7ec792b14be946a05ab998a38e.zip external_llvm-d8a33ddcfeb29e7ec792b14be946a05ab998a38e.tar.gz external_llvm-d8a33ddcfeb29e7ec792b14be946a05ab998a38e.tar.bz2 |
Currently, createMachOStreamer() is invoked directly in llvm-mc which
isn't ideal if we want to be able to use another object file format.
Add a createObjectStreamer() factory method so that the correct object
file streamer can be instantiated for a given target triple.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104318 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-mc')
-rw-r--r-- | tools/llvm-mc/llvm-mc.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/llvm-mc/llvm-mc.cpp b/tools/llvm-mc/llvm-mc.cpp index 18ab98e..ca098e1 100644 --- a/tools/llvm-mc/llvm-mc.cpp +++ b/tools/llvm-mc/llvm-mc.cpp @@ -301,7 +301,8 @@ static int AssembleInput(const char *ProgName) { assert(FileType == OFT_ObjectFile && "Invalid file type!"); CE.reset(TheTarget->createCodeEmitter(*TM, Ctx)); TAB.reset(TheTarget->createAsmBackend(TripleName)); - Str.reset(createMachOStreamer(Ctx, *TAB, *Out, CE.get(), RelaxAll)); + Str.reset(TheTarget->createObjectStreamer(TripleName, Ctx, *TAB, + *Out, CE.get(), RelaxAll)); } AsmParser Parser(SrcMgr, Ctx, *Str.get(), *MAI); |