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

jstedfast / MimeKit
95%
master: 95%

Build:
Build:
LAST BUILD BRANCH: nullable-api2
DEFAULT BRANCH: master
Repo Added 28 Jun 2015 11:55PM UTC
Files 191
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

LAST BUILD ON BRANCH unix2dos-indexof
branch: unix2dos-indexof
CHANGE BRANCH
x
Reset
  • unix2dos-indexof
  • HEAD
  • binary-quoted-printable-decoder
  • bouncycastle2.0
  • core
  • crypto-abstractions
  • dependabot/nuget/System.Memory-4.5.5
  • dependabot/nuget/nunit-4.0.0
  • hwaccel-base64
  • issue682
  • master
  • mime-compliance
  • mime-compliance2
  • mimereader
  • mimereader-span
  • mimereader-span2
  • nullable-api
  • nullable-api2
  • parser-options-create
  • refs/pull/1072/merge
  • refs/pull/1162/merge
  • refs/pull/1163/merge
  • refs/pull/1176/merge
  • refs/tags/2.12.0
  • refs/tags/3.3.0
  • refs/tags/3.4.1
  • refs/tags/3.4.3
  • rfc2047-perf
  • rfc2047-tokens
  • smime-revocation-checks
  • stream-spans
  • unsafe-scancontent
  • vnext

10 May 2025 04:59PM UTC coverage: 94.826% (+0.004%) from 94.822%
4.12.0.1635

Pull #1163

coveralls.net

jstedfast
Optimized Unix2DosFilter to use Span<T>.IndexOf() and CopyTo()

Unfortunately, this optimization is not all rainbows and sunshine.

For short lines, and especially the pathological cases where the input is
nothing but "\n\n\n\n..." or "\r\n\r\n\r\n...", performance really suffers
with this patch (as seen in the benchmark results below).

Holding off on merging this until I can think up a better solution that
is better in all cases (or at least not significantly worse in the
pathological cases).

BenchmarkDotNet v0.14.0, Windows 11 (10.0.26100.3775)
Intel Core i7-9700 CPU 3.00GHz, 1 CPU, 8 logical and 8 physical cores
.NET SDK 9.0.300-preview.0.25177.5
  [Host]     : .NET 8.0.15 (8.0.1525.16413), X64 RyuJIT AVX2
  DefaultJob : .NET 8.0.15 (8.0.1525.16413), X64 RyuJIT AVX2

| Method                     | Mean       | Error     | StdDev    |
| ---------------------------|-----------:|----------:|----------:|
| Unix2Dos_LoremIpsumDos     | 4,042.9 ns |  50.29 ns |  47.04 ns |
| Unix2Dos_LoremIpsumUnix    | 2,642.5 ns |  47.31 ns |  66.33 ns |
| Unix2Dos_PathologicalDos   | 2,296.2 ns |  25.69 ns |  22.77 ns |
| Unix2Dos_PathologicalUnix  | 1,349.1 ns |  15.80 ns |  13.19 ns |
| Unix2Dos2_LoremIpsumDos    |   616.8 ns |  12.10 ns |  13.45 ns |
| Unix2Dos2_LoremIpsumUnix   |   588.5 ns |  10.54 ns |   8.80 ns |
| Unix2Dos2_PathologicalDos  | 7,154.4 ns | 122.12 ns | 114.23 ns |
| Unix2Dos2_PathologicalUnix | 5,717.4 ns |  71.87 ns |  63.71 ns |
Pull Request #1163: Optimized Unix2DosFilter to use Span<T>.IndexOf() and CopyTo()

32163 of 33918 relevant lines covered (94.83%)

0.95 hits per line

Relevant lines Covered
Build:
Build:
33918 RELEVANT LINES 32163 COVERED LINES
0.95 HITS PER LINE
Source Files on unix2dos-indexof
  • Tree
  • List 188
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
4.12.0.1635 unix2dos-indexof Optimized Unix2DosFilter to use Span<T>.IndexOf() and CopyTo() Unfortunately, this optimization is not all rainbows and sunshine. For short lines, and especially the pathological cases where the input is nothing but "\n\n\n\n..." or "\r\n\r\n\r\... Pull #1163 10 May 2025 05:05PM UTC jstedfast coveralls.net
94.83
See All Builds (2614)
  • Repo on GitHub
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