cancel
Showing results for 
Search instead for 
Did you mean: 

OpenGL & Vulkan

vpupkin
Journeyman III

Direct3D & OpenCL & pixel shaders cooperation problem

Hello!

I'm a simple user, not a developer, but I need help on an issue that requires a developer's level of expertise.

Briefly, I'm running a program that is using Direct3D, OpenCL and pixel shaders at the same time. Cooperation of these 3 entities leads to a critical decrease of performance, which begins a couple of minutes after the program startup.

Now, the details. I'm running a video player with a frame interpolator and a 3rd party video renderer attached to it. The frame interpolator uses OpenCL for its functioning and the renderer uses Direct3D9. In addition to that, certain image processing algorithms in the renderer are implemented as pixel shaders, so when you activate them, shaders also start running.

But when I activate these shaders, a trouble happens. For the first couple of minutes the player runs smoothly, but after that CPU load suddenly rises and the renderer starts dropping frames of video. I know it's the renderer because it shows on screen statistics with the renderer frame queue among them, and the queue gets almost empty at that moment. There's also the decoder queue, which precedes rendering queue, and sometimes it gets empty too.

I've been trying to solve the problem by switching different settings, but it's useless, which leads me to the conclusion that source of the problem lies on a lower level than the programs themselves, I guess in the APIs. As the trouble doesn't begin at once, I presume that there is some memory buffer somewhere in this chain, which starts to fill with movie playback beginning and when it overflows, frames start dropping.

I need to track the source of this problem. If these symptoms give you an idea of what's going on, tell me. If not, tell me what tools can make a low-level diagnostics to find the source and how to use them for this purpose. I've already tried running CodeXL on the player's process, but somewhy it's not able to capture OpenCL calls, like they are not there.

If you need additional information, tell me.

0 Likes
Reply
11 Replies
dorisyan
Staff
Staff

Re: Direct3D & OpenCL & pixel shaders cooperation problem

Hello dipak, could you help to contact the DX/OpenCL team?

0 Likes
Reply
dipak
Staff
Staff

Re: Direct3D & OpenCL & pixel shaders cooperation problem

From the above description, it is not clear whether the issue is related to OpenCL or DX or both. Hence, first I would suggest vpupkin to use some profiling/debugging tools like RenderDoc , GPUView to check if he can identify any bottleneck or any suspected region. Based on the observation, I can report to the appropriate team. Otherwise, I need a repro to open a ticket.

Thanks.

0 Likes
Reply
vpupkin
Journeyman III

Re: Direct3D & OpenCL & pixel shaders cooperation problem

I've already said that I tried running CodeXL. I tried running RenderDoc as well, but the result was similar - nothing was displayed in program window and there were no messages of any kind like if that program wasn't using the APIs at all.

Can you tell me why these monitoring tools don't capture anything?

0 Likes
Reply
dipak
Staff
Staff

Re: Direct3D & OpenCL & pixel shaders cooperation problem

I'm not sure why these tools failed to capture any information. Please try GPUView once. Also please provide a repro to investigate the problem.

0 Likes
Reply
vpupkin
Journeyman III

Re: Direct3D & OpenCL & pixel shaders cooperation problem

As for GPUView, I'm not installing non-open source programs, so I want to find out what's wrong with those I have. I can provide additional information if you guide me in troubleshooting them. As for repro, I don't know what it is.

0 Likes
Reply
dipak
Staff
Staff

Re: Direct3D & OpenCL & pixel shaders cooperation problem

"Repro" means a reproducible test-case. Please provide a complete test-case that manifests the issue.

By the way, GPUView is a development tool for determining the performance of the graphics processing unit (GPU) and CPU. It is part of Windows Performance Toolkit (WPT). Sometimes GPUView traces are useful to find any performance bottleneck.

0 Likes
Reply
vpupkin
Journeyman III

Re: Direct3D & OpenCL & pixel shaders cooperation problem

First, will you guide me with troubleshooting those programs or not? This was my main question.

Second, how can I give you a reproducible case? Do you need a piece of video that is suffering from frame drops? Then what will you do with it? Will you install all the programs that I have installed to reproduce it?

And last, I've said that I won't be using GPUView, so I don't need any explanations of it.

0 Likes
Reply
dipak
Staff
Staff

Re: Direct3D & OpenCL & pixel shaders cooperation problem

As I already said, I'm not sure why CodeXL and RenderDoc couldn't capture any profiling information in this case. For any help regarding these tools, I would suggest you to check their related support forums here:

Issues · GPUOpen-Tools/CodeXL · GitHub --- for CodeXL

Issues · baldurk/renderdoc · GitHub  ---- for RenderDoc

We have a separate team that reproduces and validates the user reported issues. If I get a reproducible test-case, I can forward it to them. The package should include following details:

  1. a standalone application or executable
  2. any dependent files and settings that are required to run the executable
  3. target setup information
  4. steps to reproduce the issue
  5. expected behavior with/without issue [i.e. how to detect the issue if reproducible]

[Note: It is recommended to provide the test-case as simple as possible and remove any redundant files that are not directly related to the issue.]

If the package size is large, please upload the package to a public file repository and share us the download link. If privacy is concerned, you can send me the download link (and password, if any) via private message or email.

Thanks.

0 Likes
Reply
vpupkin
Journeyman III

Re: Direct3D & OpenCL & pixel shaders cooperation problem

I want to make it clear. So you are an AMD employee and you have a team that investigates the user issues, is that correct? If so, how do these issues need to be related to AMD in order to be investigated? Does the issue have to be happening with the AMD implementation of OpenCL or DirectX (or DirectX is fully implemented in Windows, not on the GPU?) on AMD GPU? And the last - how long does this team exist and why did you decide to create it? And can a user with an issue report to it directly in some way?

0 Likes
Reply