Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Launch Bounds #144

Open
wants to merge 5 commits into
base: sycl-develop
Choose a base branch
from

Conversation

AD2605
Copy link
Collaborator

@AD2605 AD2605 commented Oct 18, 2024

Small PR to add Launch bounds to the cuda launch.
Also force inlines the device_kernel which leads to no call instructions.

This increases the performance in the benchmarks, making the SYCL path, roughly equal or better than the CUDA one

@@ -53,6 +53,7 @@ if(NOT "${DPCPP_SYCL_ARCH}" STREQUAL "")
if("${DPCPP_SYCL_TARGET}" STREQUAL "nvptx64-nvidia-cuda")
list(APPEND DPCPP_FLAGS "-Xsycl-target-backend")
list(APPEND DPCPP_FLAGS "--cuda-gpu-arch=${DPCPP_SYCL_ARCH}")
list(APPEND DPCPP_FLAGS "-fgpu-inline-threshold=1000000;")
Copy link
Collaborator

Choose a reason for hiding this comment

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

If this still needed if we use __attribute__((always_inline)) inline?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I remember that back in portFFT, we had to increase the inline threshold, in combination with always_inline,
hence I went ahead with this, and have not tested it individually.
I can try without it, and will remove it if not required

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ran without the inline-threshold...
it apparently is required

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.

2 participants