Shad-o-Scan User Manual, Rev04
22
Shad-o-Scan 3001/4501 X-Ray Detector
Teledyne DALSA
Interrupt Moderation
Normally, each time a packet is received by the network card, the associated driver
will receive an interrupt. Obviously, when the packet rate is very high (that is, at high
transfer rate which is common for 5GigE Vision systems), this represents significant
overhead. Most network cards have introduced an interrupt moderation mode where
the card waits to have received a certain number of packets over a maximum period
of time before issuing the interrupt. This helps reduce the burden on the CPU as it can
process multiple packets during the same interruption.
The 5Gbit adapter provides a configuration parameter to manually adjust the NIC
interrupt moderation rate. By default the NIC driver sets this to Adaptive where the
interrupt rate automatically balances packet transmission interrupts and host CPU
performance. In most cases no manual optimization of the Interrupt Moderation Rate
parameter is required.
In some conditions, video frames from the 5GigE Vision detector may be transferred
to the host display or memory buffer as data bursts instead of a smooth continuous
stream. The NIC may be over-moderating acquisition interrupts to avoid over-
loading the host CPU with interrupts. If priority is required for acquisition transfers
(i.e. a more real-time system response to the detector transfer) then the moderation
rate should be set to “maximum” by manually adjusting the NIC parameter.
In the end, this is a compromise:
1. Enable interrupt moderation to minimize CPU usage, at the expense of a slight
increase in latency (
recommended
).
2. Disable interrupt moderation to favor responsiveness of real-time system with a
drawback in CPU usage.
In most situations, extra latency introduced by interrupt moderation is very low and
thus the gain on CPU performance becomes more beneficial.
Receive Buffers
Under certain conditions the host PC system CPU may be busy with tasks other than
the imaging application. Incoming image packets remain in the PC memory allocated
to store packets instead of immediately being copied into the image buffer. By
increasing the number of NIC (network interface card) receive buffers, more
incoming image packets can be stored by the NIC before it must start discarding
them. This provides more time for the PC to switch tasks and move image packets to
the image buffer.
Not all network boards allow increases to their receive buffer count. Among those
that do, different versions will have different maximum receive descriptor values.
We recommend
increasing the receive buffer size to the maximum permitted
by the
network card, in order to provide more buffering capacity when needed.