Skip to content

Conversation

@Silv3S
Copy link
Contributor

@Silv3S Silv3S commented Oct 23, 2025

BUILD_SPLIT_KERNEL_LIB looks like workaround, which is no longer needed in new compiler versions. From release notes

The compiler team introduced device image compression in version 2025.0.1, and this feature is now enabled in oneMKL 2025.2 builds. It facilitates the reduction in size of SYCL libraries with large kernels by approximately 12% to 40% for both static and dynamic libraries on Linux, as well as dynamic libraries on Windows.

Also this flag can't be used for Debug/RelWithDefInfo builds, as for these configs BUILD_SEPARATE_OPS takes precedence

if(CMAKE_BUILD_TYPE MATCHES "(Debug|RelWithDebInfo)")
  set(BUILD_SEPARATE_OPS TRUE)
endif()

...

if(BUILD_SEPARATE_OPS)
  ...
elseif(BUILD_SPLIT_KERNEL_LIB OR __INTEL_LLVM_COMPILER LESS 20250004 OR ICX_DATE LESS 20241205)
  ...
else()
  ...
endif()

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes the BUILD_SPLIT_KERNEL_LIB flag and its associated conditional logic for splitting SYCL kernels into multiple libraries. The change simplifies the build configuration by eliminating a workaround that was needed for older compilers that didn't support device code compression.

Key Changes:

  • Removed entire conditional block checking for BUILD_SPLIT_KERNEL_LIB or compiler versions older than specific thresholds
  • Eliminated logic for categorizing and splitting SYCL kernels into multiple specialized libraries (binary, unary, reduce, activation, foreach, tensor, norm/loss, polynomial, distribution, and others)
  • Streamlined build process to use only the standard build path

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/BuildOnWindows.cmake Removed 200+ lines of code handling split kernel libraries for Windows builds, including 10 separate library targets and their categorization logic
src/BuildOnLinux.cmake Removed ~85 lines of code handling split kernel libraries for Linux builds, including 4 separate library targets and their categorization logic

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@Silv3S Silv3S mentioned this pull request Oct 23, 2025
Copy link
Contributor

@guangyey guangyey left a comment

Choose a reason for hiding this comment

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

LGTM.
Let's ask @EikanWang and @fengyuan14 for the final stamp.

@guangyey guangyey added the windows_ci Only for Windows CI trigger label Oct 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

windows_ci Only for Windows CI trigger

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants