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

[instrument] Improve sampled timer and stopwatch performance #3191

Merged
merged 2 commits into from
Feb 8, 2021

Conversation

vdarulis
Copy link
Collaborator

@vdarulis vdarulis commented Feb 8, 2021

What this PR does / why we need it:

name                             old time/op  new time/op  delta
SampledTimer                     18.0ns ± 3%  11.0ns ± 5%  -38.92%  (p=0.000 n=9+9)
SampledTimer-6                   33.5ns ± 2%   2.1ns ±11%  -93.59%  (p=0.000 n=9+10)
SampledTimer-12                  30.5ns ± 7%   1.6ns ± 5%  -94.80%  (p=0.000 n=10+10)
SampledTimerLowRate              18.0ns ± 4%  10.6ns ± 1%  -40.76%  (p=0.000 n=10+10)
SampledTimerLowRate-6            33.5ns ± 2%   2.0ns ± 2%  -94.17%  (p=0.000 n=10+8)
SampledTimerLowRate-12           29.5ns ± 5%   1.6ns ± 6%  -94.65%  (p=0.000 n=10+10)
SampledTimerStopwatch             100ns ± 2%    89ns ± 1%  -11.12%  (p=0.000 n=10+10)
SampledTimerStopwatch-6          37.3ns ± 3%  16.1ns ± 4%  -56.89%  (p=0.000 n=10+10)
SampledTimerStopwatch-12         33.1ns ± 5%  11.9ns ± 7%  -63.94%  (p=0.000 n=10+10)
SampledTimerStopwatchLowRate     22.1ns ± 7%   9.4ns ± 1%  -57.59%  (p=0.000 n=10+9)
SampledTimerStopwatchLowRate-6   31.6ns ± 3%   1.7ns ± 8%  -94.47%  (p=0.000 n=10+10)
SampledTimerStopwatchLowRate-12  27.3ns ± 6%   1.6ns ± 5%  -94.01%  (p=0.000 n=10+10)

Special notes for your reviewer:

Does this PR introduce a user-facing and/or backwards incompatible change?:


Does this PR require updating code package or user-facing documentation?:


@vdarulis vdarulis merged commit fa20e1d into master Feb 8, 2021
@vdarulis vdarulis deleted the v/sampletimers branch February 8, 2021 18:19
soundvibe pushed a commit that referenced this pull request Feb 10, 2021
* master: (30 commits)
  [dbnode] Use go context to cancel index query workers after timeout (#3194)
  [aggregator] Fix change ActivePlacement semantics on close (#3201)
  [aggregator] Simplify (Active)StagedPlacement API (#3199)
  [aggregator] Checking if metadata is set to default should not cause copying (#3198)
  [dbnode] Remove readers and writer from aggregator API (#3122)
  [aggregator] Avoid large copies in entry rollup comparisons by making them more inline-friendly (#3195)
  [dbnode] Re-add aggregator doc limit update (#3137)
  [m3db] Do not close reader in filterFieldsIterator.Close() (#3196)
  Revert "Remove disk series read limit (#3174)" (#3193)
  [instrument] Improve sampled timer and stopwatch performance (#3191)
  Omit unset fields in metadata json (#3189)
  [dbnode] Remove left-over code in storage/bootstrap/bootstrapper (#3190)
  [dbnode][coordinator] Support match[] in label endpoints (#3180)
  Instrument the worker pool with the wait time (#3188)
  Instrument query path (#3182)
  [aggregator] Remove indirection, large copy from unaggregated protobuf decoder (#3186)
  [aggregator] Sample timers completely (#3184)
  [aggregator] Reduce error handling overhead in rawtcp server (#3183)
  [aggregator] Move shardID calculation out of critical section (#3179)
  Move instrumentation cleanup to FetchTaggedResultIterator Close() (#3173)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants