llvm
c0483d73 - [SYCL][NFC] Update includes in DPC++ headers. (#10648)

Commit
2 years ago
[SYCL][NFC] Update includes in DPC++ headers. (#10648) These changes were done in semi-automatic mode by [include what you use](https://github.com/include-what-you-use/include-what-you-use/) tool. The caveat is that this tool doesn't support SYCL compilation mode, so it analyses only host code and I had to manually adjust includes for the device compilation. The tool annotated each include with the symbols declared in the included header and used in the code. I tired to apply following structure to includes where it's possible: ```c++ // <copyright header> #pragma once #include "local/includes" #include <sycl/includes> #ifdef .. #include <conditional/includes> #endif #include <standard_library> ``` Removed sycl/include/sycl/detail/sycl_fe_intrins.hpp and sycl/include/sycl/detail/service_kernel_names.hpp - declarations from these headers are used only once, so there is sense in moving them to a separate headers. I've put a few comments for follow-up actions: 1. sycl/include/sycl/handler.hpp includes 57 headers, which seems to much. 2. sycl/include/sycl/info/info_desc.hpp and sycl/include/sycl/detail/info_desc_helpers.hpp - includes .def files, which depend on previous includes, doesn't sound like a good idea. 3. sycl/include/sycl/detail/kernel_desc.hpp - uses __SYCL_EXPORT, which doesn't sounds right to me, but I might be missing something.
Author
Parents
Loading