Erick Tryzelaar
2009-Aug-14 00:53 UTC
[LLVMdev] How shall we modify llvm's OCaml binding to support LLVMContext?
I've partially ported the OCaml bindings to support LLVMContext, and I wanted to get people's opinion on how to implement it in the API. For the LLVM's C++ api, many key functions were modified to only take a LLVMContext, such as replacing the global variable Type::FloatTy with a function Type::getFloatTy(LLVMContext&). For llvm-c though, we need to maintain backwards compatibility so we've modified LLVMFloatType() to internally use getGlobalContext(), and added LLVMFloatTypeInContext(LLVMContextRef) in order to explicitly choose which context to use. So, the question is what do we do with OCaml? Do we feel that we can break backwards compatibility and force passing around the LLVMContext, or should I follow llvm-c's lead, and add a bunch of *_in_context functions so that the API doesn't change? -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20090813/58cf1870/attachment.html>
Seemingly Similar Threads
- ConstantFP->getType() is not right
- [LLVMdev] JIT : Does it cache the compiled code of executed functions upon runFunction(..)?
- [LLVMdev] Calling functions
- [LLVMdev] Manipulating basic blocks with the C bindings
- [LLVMdev] JIT : Does it cache the compiled code of executed functions upon runFunction(..)?