diff options
author | Chris Lattner <sabre@nondot.org> | 2010-02-12 23:12:47 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-02-12 23:12:47 +0000 |
commit | 86020e46289643de2f8c7603b550ffc8b6aff376 (patch) | |
tree | b6c3f40f913038d508d598a30a30d2f4a15dbc69 /include/llvm | |
parent | 3174f6703e534366382390b7c7daa913483f4340 (diff) | |
download | external_llvm-86020e46289643de2f8c7603b550ffc8b6aff376.zip external_llvm-86020e46289643de2f8c7603b550ffc8b6aff376.tar.gz external_llvm-86020e46289643de2f8c7603b550ffc8b6aff376.tar.bz2 |
give MCCodeEmitters access to the current MCContext.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96038 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r-- | include/llvm/Target/TargetRegistry.h | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/include/llvm/Target/TargetRegistry.h b/include/llvm/Target/TargetRegistry.h index 1738997..37380ab 100644 --- a/include/llvm/Target/TargetRegistry.h +++ b/include/llvm/Target/TargetRegistry.h @@ -72,7 +72,8 @@ namespace llvm { const MCAsmInfo &MAI, raw_ostream &O); typedef MCCodeEmitter *(*CodeEmitterCtorTy)(const Target &T, - TargetMachine &TM); + TargetMachine &TM, + MCContext &Ctx); private: /// Next - The next registered target in the linked list, maintained by the @@ -236,10 +237,10 @@ namespace llvm { /// createCodeEmitter - Create a target specific code emitter. - MCCodeEmitter *createCodeEmitter(TargetMachine &TM) const { + MCCodeEmitter *createCodeEmitter(TargetMachine &TM, MCContext &Ctx) const { if (!CodeEmitterCtorFn) return 0; - return CodeEmitterCtorFn(*this, TM); + return CodeEmitterCtorFn(*this, TM, Ctx); } /// @} @@ -613,8 +614,9 @@ namespace llvm { } private: - static MCCodeEmitter *Allocator(const Target &T, TargetMachine &TM) { - return new CodeEmitterImpl(T, TM); + static MCCodeEmitter *Allocator(const Target &T, TargetMachine &TM, + MCContext &Ctx) { + return new CodeEmitterImpl(T, TM, Ctx); } }; |