[llvm-dev] Help with getting a Module

Revital1 Eres via llvm-dev llvm-dev at lists.llvm.org
Thu Nov 26 01:03:04 PST 2015


Hello,

I have several IR's I read using parseIRFile, each with it's own module 
saved in LazyEmitLayer.addModuleSet.
(as in Kaleidoscope/Orc/fully_lazy example)
The modules are defined as std::unique_ptr<Module>  and 
every time they are passed as a parameter to a function std:move is called 
on them.
IIUC I can not save pointers to the modules because there is only one 
reference to each of them stored in LazyEmitLayer.
Given a function name I want to get the module it belongs to similar to 
findUnmangledSymbol function but instead of returning 
JITSymbol I would like to get the module the function is in.
I haven't seen such function and before implementing it I wonder if I've 
missed something.

Thanks,
Revital

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151126/df0d6b44/attachment.html>


More information about the llvm-dev mailing list