Latency (engineering)
This article needs additional citations for verification. (April 2011) |
Latency, from a general point of view, is a time delay between the
Latency is physically a consequence of the limited velocity at which any physical interaction can propagate. The magnitude of this velocity is always less than or equal to the speed of light. Therefore, every physical system with any physical separation (distance) between cause and effect will experience some sort of latency, regardless of the nature of the stimulation to which it has been exposed.
The precise definition of latency depends on the system being observed or the nature of the simulation. In
Communications
Capital markets
Joel Hasbrouck and Gideon Saar (2011) measure latency to execute financial transactions based on three components: the time it takes for information to reach the trader, execution of the trader's algorithms to analyze the information and decide a course of action, and the generated action to reach the exchange and get implemented. Hasbrouck and Saar contrast this with the way in which latencies are measured by many trading venues that use much more narrow definitions, such as the processing delay measured from the entry of the order (at the vendor's computer) to the transmission of an acknowledgment (from the vendor's computer).[3] Trading using computers has developed to the point where millisecond improvements in network speeds offer a competitive advantage for financial institutions.[4]
Packet-switched networks
Network latency in a
However, in a non-trivial network, a typical packet will be forwarded over multiple links and gateways, each of which will not begin to forward the packet until it has been completely received. In such a network, the minimal latency is the sum of the transmission delay of each link, plus the forwarding latency of each gateway. In practice, minimal latency also includes queuing and processing delays. Queuing delay occurs when a gateway receives multiple packets from different sources heading toward the same destination. Since typically only one packet can be transmitted at a time, some of the packets must queue for transmission, incurring additional delay. Processing delays are incurred while a gateway determines what to do with a newly received packet. Bufferbloat can also cause increased latency that is an order of magnitude or more. The combination of propagation, serialization, queuing, and processing delays often produces a complex and variable network latency profile.
Latency limits total
Fiber optics
Latency in
Due to imperfections in the fiber, light degrades as it is transmitted through it. For distances of greater than 100 kilometers, amplifiers or regenerators are deployed. Latency introduced by these components needs to be taken into account.
Satellite transmission
Satellites in geostationary orbits are far enough away from Earth that communication latency becomes significant – about a quarter of a second for a trip from one ground-based transmitter to the satellite and back to another ground-based transmitter; close to half a second for two-way communication from one Earth station to another and then back to the first. Low Earth orbit is sometimes used to cut this delay, at the expense of more complicated satellite tracking on the ground and requiring more satellites in the satellite constellation to ensure continuous coverage.
Audio
Audio latency is the delay between when an audio signal enters and when it emerges from a system. Potential contributors to latency in an audio system include
Video
Video latency refers to the degree of delay between the time a transfer of a video stream is requested and the actual time that transfer begins. Networks that exhibit relatively small delays are known as low-latency networks, while their counterparts are known as high-latency networks.
Workflow
Any individual workflow within a system of workflows can be subject to some type of operational latency. It may even be the case that an individual system may have more than one type of latency, depending on the type of participant or goal-seeking behavior. This is best illustrated by the following two examples involving air travel.
From the point of view of a passenger, latency can be described as follows. Suppose John Doe flies from London to New York. The latency of his trip is the time it takes him to go from his house in England to the hotel he is staying at in New York. This is independent of the throughput of the London-New York air link – whether there were 100 passengers a day making the trip or 10000, the latency of the trip would remain the same.
From the point of view of flight operations personnel, latency can be entirely different. Consider the staff at the London and New York airports. Only a limited number of planes are able to make the transatlantic journey, so when one lands they must prepare it for the return trip as quickly as possible. It might take, for example:
- 35 minutes to clean a plane
- 15 minutes to refuel a plane
- 10 minutes to load the passengers
- 30 minutes to load the cargo
Assuming the above are done consecutively, minimum plane turnaround time is:
- 35 + 15 + 10 + 30 = 90
However, cleaning, refueling and loading the cargo can be done at the same time. Passengers can only be loaded after cleaning is complete. The reduced latency, then, is:
- 35 + 10 = 45
- 15
- 30
- Minimum latency = 45
The people involved in the turnaround are interested only in the time it takes for their individual tasks. When all of the tasks are done at the same time, however, it is possible to reduce the latency to the length of the longest task. If some steps have prerequisites, it becomes more difficult to perform all steps in parallel. In the example above, the requirement to clean the plane before loading passengers results in a minimum latency longer than any single task.
Mechanics
Any mechanical process encounters limitations modeled by
Computer hardware and software systems
Computers run instructions in the context of a process. In the context of computer multitasking, the execution of the process can be postponed if other processes are also executing. In addition, the operating system can schedule when to perform the action that the process is commanding. For example, suppose a process commands that a computer card's voltage output be set high-low-high-low and so on at a rate of 1000 Hz. The operating system schedules the process for each transition (high-low or low-high) based on a hardware clock such as the High Precision Event Timer. The latency is the delay between the events generated by the hardware clock and the actual transitions of voltage from high to low or low to high.
Many
On embedded systems, the real-time execution of instructions is often supported by a real-time operating system.
Note that in
Simulations
In simulation applications, latency refers to the time delay, often measured in milliseconds, between initial input and output clearly discernible to the simulator trainee or simulator subject. Latency is sometimes also called transport delay. Some authorities[who?] distinguish between latency and transport delay by using the term latency in the sense of the extra time delay of a system over and above the reaction time of the vehicle being simulated, but this requires detailed knowledge of the vehicle dynamics and can be controversial.
In simulators with both visual and motion systems, it is particularly important that the latency of the motion system not be greater than of the visual system, or symptoms of simulator sickness may result. This is because, in the real world, motion cues are those of acceleration and are quickly transmitted to the brain, typically in less than 50 milliseconds; this is followed some milliseconds later by a perception of change in the visual scene. The visual scene change is essentially one of change of perspective or displacement of objects such as the horizon, which takes some time to build up to discernible amounts after the initial acceleration which caused the displacement. A simulator should, therefore, reflect the real-world situation by ensuring that the motion latency is equal to or less than that of the visual system and not the other way round.
See also
- Age of Information
- Feedback
- Interrupt latency
- Jitter
- Lead time
- Memory latency
- Performance engineering
- Response time (technology)
- Responsiveness
References
- ^ "Latency" Archived 2021-04-22 at the Wayback Machine Retrieved 2020-10-27.
- ^ Souders, Steve. "Velocity and the Bottom Line". Retrieved 23 February 2023.
- ^ Hasbrouck, Joel; Saar, Gideon. "Low-Latency Trading" (PDF). p. 1. Archived from the original (PDF) on 11 November 2011. Retrieved 18 July 2011.
- ^ "High-frequency trading: when milliseconds mean millions". The Telegraph. Retrieved 2018-03-25.
- ^ "Don't misuse ping!". Archived from the original on 12 October 2017. Retrieved 29 April 2015.
- ^ Shane Chen (2005). "Network Protocols Discussion / Traffic Shaping Strategies". knowplace.org. Archived from the original on 2007-01-09.
- ^ "Basic QoS part 1 – Traffic Policing and Shaping on Cisco IOS Router". The CCIE R&S. 19 September 2012. Retrieved 29 April 2015.
- ISBN 9781119713012.
Further reading
- M. Brian Blake (December 2003). "Coordinating Multiple Agents for Workflow-Oriented Process Orchestration" (PDF). Information Systems and E-Business Management Journal. Springer-Verlag. Archived from the original (PDF) on 2006-09-01.