Buffer underrun
This article needs additional citations for verification. (January 2017) |
In
In terms of
The terms buffer underrun and buffer underflow are also used for meaning buffer underwrite, a condition similar to buffer overflow, but where the program is tricked into writing before the beginning of the buffer, overriding potential data there, like
General causes and solutions
Buffer underruns are often the result of transitory issues involving the connection which is being buffered: either a connection between two processes, with others competing for
The simplest guard against such problems is to increase the size of the buffer—if an incoming data stream needs to be read at 1 bit per second, a buffer of 10 bits would allow the connection to be blocked for up to 10 seconds before failing, whereas one of 60 bits would allow a blockage of up to a minute. However, this requires more memory to be available to the process or device, which can be expensive. It assumes that the buffer starts full—requiring a potentially significant pause before the reading process begins—and that it will always remain full unless the connection is currently blocked. If the data does not, on average, arrive faster than it is needed, any blockages on the connection will be cumulative; "dropping" one bit every minute on a hypothetical connection with a 60-bit buffer would lead to a buffer underrun if the connection remained active for an hour. In real-time applications, a large buffer size also increases the latency between input and output, which is undesirable in low-latency applications such as video conferencing.
CD and DVD recording issues
Buffer underruns can cause serious problems during
Another way to protect against the problem, when using
Multimedia playback
If the
The buffer in an
Intentionally imitating this audio glitch during the creation of music or sound art, either by manually splicing audio or re-triggering samples, or by using plugins, is called the Stutter edit.