Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tracing: optimize span.Finish #73398

Merged

Commits on Dec 2, 2021

  1. tracing: optimize span.Finish

    Don't read the clock unnecessarily and also use the more efficient
    timeutil.Since(t) when reading it is necessary.
    
    This clock reading was showing up in profiles when running with tracing
    enabled, and is confirmed by a micro-benchmark:
    
    Tracer_StartSpanCtx/opts=real-32                  696ns ± 1%     593ns ± 1%  -14.74%  (p=0.008 n=5+5)
    
    Release note: None
    andreimatei committed Dec 2, 2021
    Configuration menu
    Copy the full SHA
    e4c842b View commit details
    Browse the repository at this point in the history