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

libevent / libevent / 7576301678 / 1
81%
master: 81%

Build:
DEFAULT BRANCH: master
Ran 18 Jan 2024 10:11PM UTC
Files 35
Run time 1s
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 Jan 2024 09:41PM UTC coverage: 81.035% (-0.02%) from 81.055%
7576301678.1

push

github

azat
Use read/write instead of readv/writev for single buffer

The `readv`/`writev` functions are designed for scattered I/O optimally,
their logic in the kernel is more sophisticated, compared to read/write,
which includes extra on-stack `iovec` in the kernel space, importing `iovec`
array from user space to kernel space, reading/writing with `iov_iter`, etc.
As a result, using `readv`/`writev` on single-segment `iovec` will fall into
the special branch in the kernel where it is imported as `ITER_UBUF` differed
from `ITER_IOVEC` for multiple-segments `iovec`.

Thus, it is just not worth calling `readv`/`writev` for single-segment `iovec`,
we should use `read`/`write` instead, to save it from going through the
sophisticated yet unnecessary kernel code path, circumvent a waste of
kernel on-stack memory, copying `iovec` between user space and kernel space, etc.

12797 of 15792 relevant lines covered (81.03%)

555581.01 hits per line

Source Files on job 7576301678.1
  • Tree
  • List 0
  • Changed 26
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 7576301678
  • 55899c2f on github
  • Prev Job for on master (#7525820850.1)
  • Next Job for on master (#7576317332.1)
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

© 2026 Coveralls, Inc