Skip to content

Add sycl_platform::has_aspect properties - #2412

Open
ndgrigorian wants to merge 2 commits into
masterfrom
add-sycl-platform-info-queries
Open

ndgrigorian wants to merge 2 commits into
masterfrom
add-sycl-platform-info-queries

Conversation

@ndgrigorian

Copy link
Copy Markdown
Collaborator

This PR proposes the addition of the sycl_platform::has_aspect properties to dpctl.SyclPlatform

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • Have you checked performance impact of proposed changes?
  • Have you added documentation for your changes, if necessary?
  • Have you added your changes to the changelog?
  • If this PR is a work in progress, are you opening the PR as a draft?

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown

@coveralls

coveralls commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Coverage Status

coverage: 74.93% (+0.04%) from 74.893% — add-sycl-platform-info-queries into master

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

The three new extension-aspect properties are missing from both Python and C++ test lists, leaving their property smoke checks and platform/device agreement checks uncovered.

1 open issue
What changed in this PR

This PR adds platform-wide aspect queries to dpctl.SyclPlatform, exposing capabilities supported by all devices on a platform.

Changes:

  • Adds a C API aspect query and its Cython binding.
  • Exposes 22 has_aspect_* properties with docstrings and refreshes the documented lsplatform output.
  • Adds Python and C++ checks for standard aspects, platform/device agreement, and null-platform handling.
File Description
libsyclinterface/​tests/​test_sycl_platform_interface.cpp Tests aspect queries against device capabilities and null platforms.
libsyclinterface/​source/​dpctl_sycl_platform_interface.cpp Implements the platform aspect query with error handling.
libsyclinterface/​include/​syclinterface/​dpctl_sycl_platform_interface.h Declares and documents the new C API.
dpctl/​tests/​test_sycl_platform.py Adds property checks and platform/device agreement tests.
dpctl/​_sycl_platform.pyx Adds aspect properties and updates output examples in documentation.
dpctl/​_backend.pxd Declares the C API function for Cython use.

Review effort: Balanced

Comment thread dpctl/_sycl_platform.pyx Resolved

@antonwolfy antonwolfy left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks, this looks good overall. A few points inline. The main one is that three of the new properties aren't covered by the tests. Could you also add a line to CHANGELOG.md under [dev] / Added for the new SyclPlatform.has_aspect_* properties?

Comment thread dpctl/tests/test_sycl_platform.py Resolved
Comment thread dpctl/_sycl_platform.pyx Resolved
Comment thread dpctl/_sycl_platform.pyx Resolved
Cover is_component, is_composite and ext_oneapi_ipc_memory in the Python
and C-API platform aspect tests, note empty platforms in the docstrings,
document the false-on-error return, and add a changelog entry.
@ndgrigorian
ndgrigorian force-pushed the add-sycl-platform-info-queries branch from 8560194 to efd37c7 Compare November 4, 2026 19:21

This branch has not been deployed

No deployments
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.

4 participants