I have noticed that using #include to load the headers for a library take significantly longer in cling than it does in clang. What could be the reason for this? Is there something I can do to speed up the loading of the headers? The headers I’m loading belong to cpp-netlib.
I found a ‘workaround’: There was only one function I needed to run directly from Cling (this function starts a server). So I simply compiled my server code (which needed many headers) as a shared library. Cling can use this shared library as long as you provide headers for anything you call from Cling. Since I only needed to call one function, the header file was very short and fast to process.
Hi,
That’s a good work-around.
cling needs a few extra steps compared to clang. I’ll profile to see what’s happening.
Cheers, Axel.