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

Fix logic to query the number of available devices #661

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

dlopr
Copy link
Contributor

@dlopr dlopr commented Jan 28, 2025

For the riscv mux target, GetDeviceInfos always returned 1 when called with device_infos_length = 0 and out_device_infos = nullptr to query the number of available devices, regardless of the actual number of devices detected in the system.

This fixes it by always returning the number of available devices in the system, but still only filling the provided vector up to its own capacity.

For the riscv mux target, GetDeviceInfos always returned 1 when called
with device_infos_length = 0 and out_device_infos = nullptr to query
the number of available devices, regardless of the actual number of
devices detected in the system.

This fixes it by always returning the number of available devices in the
system, but still only filling the provided vector up to its own
capacity.
@coldav coldav merged commit 4042dda into uxlfoundation:main Jan 28, 2025
12 checks passed
@dlopr dlopr deleted the fix-device-detection branch January 29, 2025 15:02
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.

None yet

2 participants