I worked on a system where sometimes I actually would get negative values when doing t2 - t1.Rarely an XKCD strip has hit me as hard as this one...
![]()
DateTime
xkcd.com
The result was then printed, and instead of ~300ms it would be -123456789... in 64b. Later in the process, some other device would not be able to parse such a large number and kaput. Turned out that another process was sometimes setting the system date in those ~300ms, and that would "reset" the seconds to "sec.0", thus resulting in the occasional negative value.
