Changes in directory llvm/include/llvm/ExecutionEngine:
ExecutionEngine.h updated: 1.34 -> 1.35 --- Log message: wrap lines to 80 columns. Add static JITCtor/InterpCtor fields --- Diffs of the changes: (+15 -5) ExecutionEngine.h | 20 +++++++++++++++----- 1 files changed, 15 insertions(+), 5 deletions(-) Index: llvm/include/llvm/ExecutionEngine/ExecutionEngine.h diff -u llvm/include/llvm/ExecutionEngine/ExecutionEngine.h:1.34 llvm/include/llvm/ExecutionEngine/ExecutionEngine.h:1.35 --- llvm/include/llvm/ExecutionEngine/ExecutionEngine.h:1.34 Wed Mar 8 12:42:33 2006 +++ llvm/include/llvm/ExecutionEngine/ExecutionEngine.h Wed Mar 22 00:06:37 2006 @@ -48,11 +48,13 @@ std::map<void *, const GlobalValue*> GlobalAddressReverseMap; public: - std::map<const GlobalValue*, void *>& getGlobalAddressMap(const MutexGuard& locked) { + std::map<const GlobalValue*, void *> & + getGlobalAddressMap(const MutexGuard &locked) { return GlobalAddressMap; } - std::map<void *, const GlobalValue*>& getGlobalAddressReverseMap(const MutexGuard& locked) { + std::map<void*, const GlobalValue*> & + getGlobalAddressReverseMap(const MutexGuard& locked) { return GlobalAddressReverseMap; } }; @@ -71,9 +73,16 @@ TD = &td; } + // To avoid having libexecutionengine depend on the JIT and interpreter + // libraries, the JIT and Interpreter set these functions to ctor pointers + // at startup time if they are linked in. + typedef ExecutionEngine *(*EECtorFn)(ModuleProvider*, IntrinsicLowering*); + static EECtorFn JITCtor, InterpCtor; + public: - /// lock - This lock is protects the ExecutionEngine, JIT, JITResolver and JITEmitter classes. - /// It must be held while changing the internal state of any of those classes. + /// lock - This lock is protects the ExecutionEngine, JIT, JITResolver and + /// JITEmitter classes. It must be held while changing the internal state of + /// any of those classes. sys::Mutex lock; // Used to make this class and subclasses thread-safe ExecutionEngine(ModuleProvider *P); @@ -156,7 +165,8 @@ void *getPointerToGlobalIfAvailable(const GlobalValue *GV) { MutexGuard locked(lock); - std::map<const GlobalValue*, void*>::iterator I = state.getGlobalAddressMap(locked).find(GV); + std::map<const GlobalValue*, void*>::iterator I = + state.getGlobalAddressMap(locked).find(GV); return I != state.getGlobalAddressMap(locked).end() ? I->second : 0; } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits