Abstract

ROOT comes with a C++ compliant interpreter cling. Cling needs to understand the content of the libraries in order to interact with them. Exposing the full shared library descriptors to the interpreter at runtime translates into increased memory footprint. ROOT’s exploratory programming concepts allow implicit and explicit runtime shared library loading. It requires the interpreter to load the library descriptor. Re-parsing of descriptors’ content has a noticeable effect on the runtime performance. Present state-of-art lazy parsing technique brings the runtime performance to reasonable levels but proves to be fragile and can introduce correctness issues. An elegant solution is to load information from the descriptor lazily and in a non-recursive way.The LLVM community advances its C++ Modules technology providing an io-efficient, on-disk representation capable to reduce build times and peak memory usage. The feature is standardized as a C++ technical specification. C++ Modules are a flexible concept, which can be employed to match CMS and other experiments’ requirement for ROOT: to optimize both runtime memory usage and performance. Cling technically “inherits” the feature, however tweaking it to ROOT scale and beyond is a complex endeavor. The paper discusses the status of the C++ Modules in the context of ROOT, supported by few preliminary performance results. It shows a step-by-step migration plan and describes potential challenges which could appear.

Highlights

  • ROOT’s 6th version introduces a set of modern tools in its core

  • The object code cannot interoperate with third-party code without a shared library descriptor

  • The ROOT Eve example measures the performance of C++ modules instead of lightweight shared library descriptors

Read more

Summary

Introduction

ROOT’s 6th version introduces a set of modern tools in its core. The LLVM-based C++ interpreter cling is one of them. The third-party code imports the description (by including a set of header files) which makes the content from the library available. The descriptors are parsed at runtime causing significant performance degradation when they contain more than a few hundred header files. Loading a shared library parses only the lightweight descriptor. The textual expansion of invariant header files in the including translation unit causes significant increase of compile times and memory usage.

Results
Conclusion
Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call