Skip to content

Conversation

@PokhodenkoSA
Copy link
Contributor

@PokhodenkoSA PokhodenkoSA commented Apr 2, 2021

This PR contains several fixes for tests which should be skipped if GPU is not available but they was not skipped.

  1. dpctl.SyclContext("gpu") raises ValueError. It seems that catching dpctl.SyclQueueCreationError is copy/past error.
  2. In test_context_can_be_used_in_queue2 exception was not caught.
  3. TestGetCurrentDevice uses context opencl:gpu:0 in several tests so it should be skipped if GPU is not available.
ctx1 = dpctl.SyclContext("gpu")
ctx0 = dpctl.SyclContext("gpu")
except dpctl.SyclQueueCreationError:
except ValueError:
Copy link
Contributor

Choose a reason for hiding this comment

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

This is good. I think we may as well introduce SyclContextCreationError and use that, for symmetry,

@PokhodenkoSA
Copy link
Contributor Author

There are also a lot of failed tests when CPU is not available too.

@PokhodenkoSA PokhodenkoSA merged commit 992d5e1 into master Apr 2, 2021
@diptorupd
Copy link
Contributor

@PokhodenkoSA @oleksandr-pavlyk We can use SYCL_DEVICE_FILTER (refer https://github.com/intel/llvm/blob/sycl/sycl/doc/EnvironmentVariables.md) to simulate testing with only a specific type of device. Can we setup multiple CI runs where we explicitly select a specific type of device and turn off other types using the environment variable?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working tests

3 participants