• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

xapi-project / xen-api / 10920124185
78%
master: 80%

Build:
Build:
LAST BUILD BRANCH: private/changleli/fix-xenops-cache
DEFAULT BRANCH: master
Ran 18 Sep 2024 10:15AM UTC
Jobs 1
Files 37
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

18 Sep 2024 10:14AM UTC coverage: 78.279%. Remained the same
10920124185

push

github

web-flow
Tracing: optimize and reduce overhead (#5958)

We've noticed some delays when tracing is enabled, and suspected it is
due to lock contention or GC activity created by the tracing module
itself.

I've added some benchmarks to measure the overhead of tracing, and made
some improvements (more improvements are possible).
The benchmarks test both a situation with no workload, and a situation
with 2 other threads: one running the same workload as the function
under test, and another that runs a very GC intensive workload.

Improved:
* when max spans limit is hit: don't spam syslog. Time goes down from
202 *milli*seconds to 14 *micro*seconds per span
* reduce lock contention: eliminate one global lock, replace with atomic
ops
* reduce allocation

We are now at ~9µs/nested span on this particular machine, but further
improvements are possible by delaying work to the exporter thread and
finishing really quickly otherwise (e.g. upstream ocaml-trace claims
~60ns/span).

When tracing is disabled the overhead is very small, just like before
(on the order of 20ns without a workload).

Before:
```
Running benchmarks (no workloads)
╭─────────────────────────────────────┬───────────────────────────┬───────────────────────────┬───────────────────────────╮
│name                                 │  major-allocated          │  minor-allocated          │  monotonic-clock          │
├─────────────────────────────────────┼───────────────────────────┼───────────────────────────┼───────────────────────────┤
│  tracing/max span overflow          │             0.0000 mjw/run│          1187.0000 mnw/run│       96214066.4652 ns/run│
│  tracing/overhead(off)              │             0.0000 mjw/run│            14.0000 mnw/run│             19.0061 ns/run│
│  tracing/overhead(on, create span)  │             2.9250 mjw/run│           496.3888 mnw/run│          25431.5210 ns/run│
│  tracing/overhead(on, no span)      │             0.0000 mjw/run│            14.0000 mnw/run│            ... (continued)

3456 of 4415 relevant lines covered (78.28%)

0.78 hits per line

Jobs
ID Job ID Ran Files Coverage
1 python3.11 - 10920124185.1 18 Sep 2024 10:15AM UTC 37
78.28
GitHub Action Run
Source Files on build 10920124185
  • Tree
  • List 37
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #10920124185
  • 7e9c2a3c on github
  • Prev Build on master (#10920109127)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc