Dibyendu Majumdar via llvm-dev
2015-Oct-17 01:02 UTC
[llvm-dev] Memory allocated for JIT compiled code
Hi, I am looking for ways to reduce the memory consumption in my JIT compiler that uses LLVM. In my implementation a compiled function lives in its own module. After compiling the function/module I would like to be able to discard any memory associated with the module but retain the compiled code. How can I do this? I am currently using MCJIT but if the new ORC API supports this then I will be happy to migrate to it. Thanks and Regards Dibyendu
Lang Hames via llvm-dev
2015-Oct-17 03:56 UTC
[llvm-dev] Memory allocated for JIT compiled code
Hi Dibyendu, I'd recommend trying ORC out - it gives you a lot more flexibility in your memory management, and aggressively frees memory by default. If you haven't used ORC before I'd check out the tutorials under llvm/examples/Kaleidoscope/Orc. The basic JIT in the 'initial' tutorial should be all you need to replace MCJIT in most cases. Cheers, Lang. On Fri, Oct 16, 2015 at 6:02 PM, Dibyendu Majumdar via llvm-dev < llvm-dev at lists.llvm.org> wrote:> Hi, > > I am looking for ways to reduce the memory consumption in my JIT > compiler that uses LLVM. In my implementation a compiled function > lives in its own module. After compiling the function/module I would > like to be able to discard any memory associated with the module but > retain the compiled code. How can I do this? > > I am currently using MCJIT but if the new ORC API supports this then I > will be happy to migrate to it. > > Thanks and Regards > > Dibyendu > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151016/19a52994/attachment.html>