Notch Block ~8ms cook time with empty layer selected

Hello,

Is it normal for Notch blocks to continue to render content in non-active layers? As a test we loaded an Empty layer (with no nodes/default settings) and it’s still taking around 8ms to cook:

Reducing the total number of layers in the block from 15 to 6 reduced our cook time from 8 to 6ms on the empty layer, so it seems like other layers affect cook times. Could this perhaps be optimized so that invisible layers do not render at all (or at least, more minimally?)

Happy to send the DFX to support if they are so inclined to take a look, cheers.

1 Like

Thanks for the optimisation tip, but no - we don’t render inactive layers. (I’d also be surprised if rendering 15x layers took just 8ms - you’d probably be seeing a much larger figure if it were the case.)

I have no idea whether TD’s cook time refers to a GPU timestamp around the Notch DX11 workload, or CPU timers around the execution of the Notch calls, but I’ll fire some possible diagnoses over anyway…
Do you have a large number of exposed parameters? Without knowing how TD’s (I presume you’re running in TD) implementation of the host works, I guess it’s possible that all exposed parameters are being sent regardless of if they’re in use on the active layer, which could cause an overhead if there are a lot (although I’d have expected this to have been hit elsewhere before). Or are you using any hardware devices (e.g. Kinect) through the Notch block? Those have a fixed overhead, although it’s generally on separate threads CPU-wise. Is your empty layer really empty? Is deferred rendering and AA turned on, for example? There are fixed overheads related to processing of those workloads, so it could inflate the time (although I wouldn’t expect to 8ms, unless you’re on a huge resolution and slow GPU.)

Support is always available and willing to have a look at your DFX if you want to send it over to be investigated further.

1 Like

Thanks for the clarifications @mattswoboda

Looks like this might be a TD issue that has been fixed in latest stable. I re-exported the blocks into a blank TD project for the latest version Derivative pushed out a few weeks ago and, as you suggest, cook times are minimal for blank layers, even with exposed pars and many layers:
image image

For anyone else encountering this issue, I recommend to upgrade to latest stable, which also publishes the Notch Block Render Time in the info panel (middle click on Notch TOP) – very useful. Cheers.

Further testing reveals that the same block rendered at 7680x4320 instead of 1280x720 uses over 2ms more compute… for a blank layer…

When trying to discern between host and block side performance issues, it is useful to load blocks up in:
C:\Program Files\FXPlayerHostD3D11_x64.exe

This is a super light block player that allows you to profile the block itself while altering variables such as resolution and exposed parameters.

1 Like

Thanks Luke! I’ll give that a try as well asap.

Also FYI, I’m referring to the Notch Block Render Time attribute, which I believe is derived from the dfxdll directly, no? I’m not really focusing on TD performance as I understand that has it’s own overhead and is outside your domain.

No, Block Render Time is not derived from the dfxdll.

Firstly, I think there’s a basic assumption here that rendering an empty block inside a media host doesn’t rendering anything on screen, so it shouldn’t take any time. That is incorrect.
The frame+depth buffers still have to be cleared; the render from Notch has to be comped into the target provided by the host; and there’s probably another copy step on the D3D11/OGL texture on the TD side. All of these steps are very fast, but not free, and they have to be done for the block to be rendered. There’s also some potential sync overhead between OGL and D3D workloads.
7680x4320 is a lot of pixels - 36x 1280x720 (and ~18x 1080p). Doing some back of envelope calculations I’d expect it takes around ~0.1ms to copy a 1080p rendertarget on GPU, so 18x that starts to produce a figure close to what you’re seeing.
In summary, if you don’t want any cost from rendering a blank layer, it’s best not to render the layer at all (the best optimisation of all).

I don’t know what “Block Render Time” refers to either, btw.

1 Like