Skip to content

Instantly share code, notes, and snippets.

@gargvaibhav64
Last active August 30, 2022 04:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gargvaibhav64/1fd2095e5229bd898a6edbb6a3830dc4 to your computer and use it in GitHub Desktop.
Save gargvaibhav64/1fd2095e5229bd898a6edbb6a3830dc4 to your computer and use it in GitHub Desktop.
Google Summer of Code'20 - Enable Modules on Windows

GSoC 2020 Enable Modules on Windows - Vaibhav Garg.

Abstract

ROOT has several features that interact with libraries and require implicit header inclusion. This can be triggered by reading or writing data on disk, or user actions at the prompt. Exposing the full shared library descriptors to the interpreter at runtime translates into an 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 runtime performance. C++ Modules are designed to minimize the reparsing of the same header content by providing an efficient on-disk representation of the C++ Code. C++ Modules had already been implemented for Unix and OS X systems. This project aimed to extend the C++ Modules support for Windows.

Milestones

  • Enable the std module on Windows.
  • ROOT's Core suite builds and works on Windows with Modules enabled.
  • ROOT builds and works on Windows with Modules enabled with flag -Droottest=Off.
  • ROOT builds and works on Windows with Modules enabled. (65% tests passing)

Code

  1. Pull Requests:

    1. Update clingUtils/CMakeLists.txt to copy module.modulemap in cling includes for Windows. #5086
    2. Remove duplicate include of subdirectory builtins/glew. #5525
    3. Backport D51910 and add stub windows modulemaps. #5294
    4. Create vcruntime.modulemap for use in Windows. #5586
    5. Fix std and libc modules on Windows. #5610
    6. Make xtimec.h and xthreads.h textual in std_msvc.modulemap. #5622
    7. Fix Core.pcm on Windows. #5636
    8. Fix Thread.pcm on Windows. #5681
    9. Remove Cling as a dependency of win32gdk. #5796
    10. Fix MathCore.pcm build on Windows. #5800
    11. Fix NO_CXXMODULE handling logic for dependencies. #5903
    12. Add missing header TEveVector.h in Eve module. #6042
    13. Fix libary path of modules for Windows. #6043
    14. Teach DLM to recognise symbols in COFF Object Files. #6154
    15. Configure tests for modules on Windows. #6179
    16. Shift to standard C++ filestreams when generating _rdict files. #6184
    17. Rename -fmodule-map-file flag to -moduleMapFile. #6227
    18. Backport D83174 - Teach AttachPreviousImpl to inherit MSInheritanceAttr attribute. #6245
  2. LLVM Reviews:

    1. Teach AttachPreviousImpl to inherit MSInheritanceAttr attribute. D83174
    2. Correctly parse LateParsedTemplates in case of multiple dependent modules. D86514

Presentation

Presentation for the work done: http://bit.ly/Vaibhav_GSoC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment