Skip to content

benchdnn: memory: gpu: enable support for RNG memory fill #3336

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

yehudaorel
Copy link
Contributor

Description

Systems with data compression enabled by the driver by default wont generate meaningful performance data with benchdnn ... --mode=F

  • Reuse ocl_philox.h routine to directly fill gpu mem with random vals via a dedicated opencl kernel.

Fixes MFDNN-12589

Checklist

General

  • Do all unit and benchdnn tests (make test and make test_benchdnn_*) pass locally for each commit?
  • Have you formatted the code using clang-format?

@yehudaorel yehudaorel requested review from a team as code owners May 27, 2025 16:14
@github-actions github-actions bot added platform:gpu-intel Codeowner: @oneapi-src/onednn-gpu-intel component:tests Codeowner: @oneapi-src/onednn-arch labels May 27, 2025
}

uint philox_4x32(long idx, uint seed) {
return ref_philox_4x32(idx >> 2, seed)[idx & 3];
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
return ref_philox_4x32(idx >> 2, seed)[idx & 3];
return ref_philox_4x32(idx, seed)[~idx & 3L];

#endif
} else if (is_sycl) {
#ifdef DNNL_WITH_SYCL
this->memset(dnnl_mem_default_perf_test_value, size, buffer_index);
Copy link
Contributor

Choose a reason for hiding this comment

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

It would be nice to keep OpenCL/SYCL behavior aligned - otherwise we make performance behavior different between runtimes and performance debugging gets less trivial.

What if we merge the PR but keep the old behavior for OpenCL until we make similar changes for the SYCL runtime?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:tests Codeowner: @oneapi-src/onednn-arch platform:gpu-intel Codeowner: @oneapi-src/onednn-gpu-intel
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants