Skip to content

[SYCL] Clean up handler.hpp transitive include chain#22147

Merged
KornevNikita merged 6 commits into
intel:syclfrom
koparasy:sycl-handler-compile-time-cleanup
Jun 10, 2026
Merged

[SYCL] Clean up handler.hpp transitive include chain#22147
KornevNikita merged 6 commits into
intel:syclfrom
koparasy:sycl-handler-compile-time-cleanup

Conversation

@koparasy

Copy link
Copy Markdown
Contributor

Drop dead/unnecessary includes from handler.hpp and its dependency chain to reduce compile-time overhead and improve header hygiene. No ABI or API changes.

Changes:

  • Split tls_code_loc_t and code_location into a new sycl/detail/code_location.hpp; common.hpp no longer carries them. Files that relied on the transitive pull now include code_location.hpp directly (accessor.hpp, buffer.hpp, buffer_impl.{hpp,cpp}, common.cpp, usm_impl.hpp, layout_tls_code_loc_t.cpp).
  • Drop 14 unused includes from cg_types.hpp; kept only kernel_handler.hpp plus required std headers.
  • Drop unused graph.hpp and compile_time_kernel_info.hpp from kernel_launch_helper.hpp.
  • Replace device.hpp with class fwd-decl in range_rounding.hpp; only const device& is used.
  • Drop unused includes from handler.hpp: cluster_group_prop.hpp, use_root_sync_prop.hpp, detail/ur.hpp, detail/string.hpp, .
  • Replace common.hpp with code_location.hpp in handler.hpp.
  • Add explicit host_profiling_info.hpp to host_task.hpp (was transitive).

E2E test fixes:

  • Tests using parallel_for_work_item relied on cg_types.hpp transitively pulling h_item.hpp. Add explicit <sycl/h_item.hpp> to: HierPar/hier_par_basic.cpp, HierPar/hier_par_indirect.cpp, HierPar/Inputs/hier_par_wgscope_impl.hpp, InorderQueue/in_order_kernels.cpp, Properties/cache_config.cpp, MemorySanitizer/local/parallel_for_work_group.cpp.

@koparasy koparasy requested review from a team as code owners May 28, 2026 01:33
@koparasy koparasy requested a review from sergey-semenov May 28, 2026 01:33
@koparasy koparasy requested a review from a team as a code owner June 2, 2026 20:13

@YuriPlyakhin YuriPlyakhin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changes to sycl/test-e2e/SpecConstants/2020 LGTM

@koparasy koparasy force-pushed the sycl-handler-compile-time-cleanup branch from ded7500 to af24b3a Compare June 2, 2026 23:10
@koparasy

koparasy commented Jun 4, 2026

Copy link
Copy Markdown
Contributor Author

@sergey-semenov can you please review this! Thank you!

@koparasy koparasy force-pushed the sycl-handler-compile-time-cleanup branch 2 times, most recently from a10feae to 7d31173 Compare June 9, 2026 14:56
@koparasy

koparasy commented Jun 9, 2026

Copy link
Copy Markdown
Contributor Author

@intel/llvm-gatekeepers please consider merging this one. The failure is unrelated

koparasy added 6 commits June 9, 2026 16:50
Drop dead/unnecessary includes from handler.hpp and its dependency chain
to reduce compile-time overhead and improve header hygiene. No ABI or API
changes.

Changes:
* Split tls_code_loc_t and code_location into a new
  sycl/detail/code_location.hpp; common.hpp no longer carries them.
  Files that relied on the transitive pull now include code_location.hpp
  directly (accessor.hpp, buffer.hpp, buffer_impl.{hpp,cpp}, common.cpp,
  usm_impl.hpp, layout_tls_code_loc_t.cpp).
* Drop 14 unused includes from cg_types.hpp; kept only kernel_handler.hpp
  plus required std headers.
* Drop unused graph.hpp and compile_time_kernel_info.hpp from
  kernel_launch_helper.hpp.
* Replace device.hpp with class fwd-decl in range_rounding.hpp; only
  const device& is used.
* Drop unused includes from handler.hpp: cluster_group_prop.hpp,
  use_root_sync_prop.hpp, detail/ur.hpp, detail/string.hpp, <tuple>.
* Replace common.hpp with code_location.hpp in handler.hpp.
* Add explicit host_profiling_info.hpp to host_task.hpp (was transitive).

E2E test fixes:
* Tests using parallel_for_work_item relied on cg_types.hpp transitively
  pulling h_item.hpp. Add explicit <sycl/h_item.hpp> to:
  HierPar/hier_par_basic.cpp, HierPar/hier_par_indirect.cpp,
  HierPar/Inputs/hier_par_wgscope_impl.hpp,
  InorderQueue/in_order_kernels.cpp, Properties/cache_config.cpp,
  MemorySanitizer/local/parallel_for_work_group.cpp.
@koparasy koparasy force-pushed the sycl-handler-compile-time-cleanup branch from 1c81909 to ccba634 Compare June 9, 2026 23:50
@KornevNikita KornevNikita merged commit e786897 into intel:sycl Jun 10, 2026
36 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants