cancel
Showing results for 
Search instead for 
Did you mean: 

OpenCL

elad
Adept I

OpenCL runtime bug when sharing texture with D3D11

I have a program that initializes 2 Direct3D11 textures.
It then extract 2 cl_mem image objects from each texture and download its content to RAM.

When using DirectX11 device created via the new D3D11On12 API (WinSDK 10.0.19041.0), the texture memory layout that OpenCL sees is inconsistent with the memory layout DirectX sees. 

If I download the textures via OpenCL API I get either a blank image or this weird result:

bad.PNG

When I download it via DirectX it looks OK:

cat.jpg

Here is a link to a self contained VS2019 solution that reproduce this bug:

link

Hardware: WX7100, Windows 10 PC. latest drivers.

0 Likes
5 Replies
dipak
Big Boss

Thank you for reporting this and providing the reproducible test-case. We will look into this and get back to you.

Thanks.

dipak
Big Boss

I was able to reproduce the issue with the above test-case. However, it seems that the code is working fine if native DX11 device is used.

I reported the issue to the OpenCL team. From their feedback, it looks like DX11 emulation via DX12 has some problems and they are already aware of this issue. Anyway, I've opened a ticket against it and attached the above reproducible test-case.

Thanks.

dipak‌ is there any update regarding this issue?

This bug is preventing us from incorporating DirectML / DirectX12 workloads in our product.
I was really hoping AMD would solve it. 

Appreciate your help,
Elad

0 Likes

The concerned team is working on this issue. I'll let you know if I get any update on this.

Thanks.

0 Likes

@dipak I see this issue  is not reproduced in the last driver version. Can you confirm it is fixed?

0 Likes