Skip to content

[SYCL] Introduce sycl-sanitizer tool #4174

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

Closed
wants to merge 7 commits into from

Conversation

alexbatashev
Copy link
Contributor

@alexbatashev alexbatashev commented Jul 23, 2021

sycl-sanitizer is a CLI tool to facilitate development of DPC++ applications. Currently sycl-sanitizer is capable of the following diagnostics:

  • USM pointer memory leaks. Report is generated at the end of program execution and contains location of leaked pointer malloc call.
  • Construction of SYCL buffers from device or shared USM pointer. The tool will abort execution of application if it attempts to create a buffer from device or shared USM pointer.
  • Construction of SYCL buffer from host USM pointer of smaller size, than buffer range. The application will be terminated.

Example usage:

sycl-sanitizer application.exe --arg1 --arg2

@alexbatashev
Copy link
Contributor Author

alexbatashev commented Sep 12, 2021

Tests: intel/llvm-test-suite#459
Depends on #4545 and #4494

sycl-sanitizer tool aims to help developers find memory leaks when
using USM pointers.
@alexbatashev alexbatashev marked this pull request as ready for review October 2, 2021 16:20
@alexbatashev alexbatashev requested review from andykaylor, tovinkere and a team as code owners October 2, 2021 16:20
@alexbatashev alexbatashev requested a review from s-kanaev October 2, 2021 16:20
@alexbatashev
Copy link
Contributor Author

@smaslov-intel FYI
We can do a similar wrapper for PI trace collector

@keryell
Copy link
Contributor

keryell commented Oct 5, 2021

Cool stuff!

@@ -3922,10 +3959,10 @@ _ZN2cl4sycl7handler20DisableRangeRoundingEv
_ZN2cl4sycl7handler20associateWithHandlerEPNS0_6detail16AccessorBaseHostENS0_6access6targetE
_ZN2cl4sycl7handler20setStateSpecConstSetEv
_ZN2cl4sycl7handler22setHandlerKernelBundleERKSt10shared_ptrINS0_6detail18kernel_bundle_implEE
_ZN2cl4sycl7handler28setStateExplicitKernelBundleEv
Copy link
Contributor

Choose a reason for hiding this comment

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

It is ABI breaking change, isn't it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, it has been re-ordered

@alexbatashev alexbatashev requested a review from s-kanaev October 6, 2021 08:40
@alexbatashev
Copy link
Contributor Author

replaced with #5389

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.

3 participants