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

stillwater-sc / universal / 41973428347
89%
master: 84%

Build:
Build:
LAST BUILD BRANCH: fix/fixpnt-quire-resolve-saturates
DEFAULT BRANCH: master
Ran 05 Nov 2026 05:50AM UTC
Jobs 1
Files 773
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

05 Nov 2026 05:20AM UTC coverage: 88.576% (+0.003%) from 88.573%
41973428347

push

github

web-flow
perf(cfloat): read and write the exponent field a limb at a time (#1924)

When the exponent field straddles limbs, exponent() copied it one bit at a
time with at(), and scale() read it back through blockbinary::to_ull(),
another bit loop. setexponent() always wrote it one bit at a time with
setbit(). isnormal(), isdenormal() and scale() run several times per add,
so these es-iteration loops caused the cliffs the #1904 benchmark found:
cfloat<196,19> with uint32_t or uint64_t limbs, and cfloat<128,15,uint8_t>,
were 3x to 5x slower than the widths around them.

A new exponentField() gathers the field a limb at a time, and
setExponentField() writes it the same way. exponent() uses the first for
the straddling case; isnormal(), isdenormal(), ismaxexpvalue() and scale()
read it directly, without a blockbinary temporary.

blocksignificand::operator<<= now indexes its block move from the source
block: the same moves in the same order. Once the exponent read became
cheap, gcc inlined further and issued a false -Waggressive-loop-optimizations
warning on the old form in two cfloat tests.

Measured with the BlockType benchmark (i7-12700K, taskset -c 2):
- gcc, 196 bits: uint64_t add 248 -> 50 ns, uint32_t 258 -> 72 ns, against
  57 and 69 ns at 256 bits.
- clang, 128 bits: uint8_t add 217 -> 91 ns.
- uint8_t/uint16_t add at 196 and 256 bits is 2.1x to 3.3x faster with both
  compilers.
- Multiply is 1.4x to 2.4x faster and divide 1.1x to 1.3x wherever the
  field straddles limbs.
The cross-BlockType bit check passes, and a main-vs-branch A/B shows no
change to posit.

New test api/exponent_field.cpp checks both functions against the per-bit
definition on random encodings, with the field inside one limb, across two
and across three. Shifting the gathered limbs by one bit fails all seven
configurations whose field straddles limbs.

Resolves #1919

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

37 of 37 new or added lines in 2 files covered. (100.0%)

1 existing line in 1 file now uncovered.

56324 of 63588 relevant lines covered (88.58%)

8865975.17 hits per line

Coverage Regressions

Lines Coverage ∆ File
1
93.16
-0.85% include/sw/universal/verification/correctly_rounded_reference.hpp
Jobs
ID Job ID Ran Files Coverage
1 41973428347.1 05 Nov 2026 05:50AM UTC 773
88.58
GitHub Action Run
Source Files on build 41973428347
  • Tree
  • List 773
  • Changed 3
  • Source Changed 2
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #41973428347
  • 82685896 on github
  • Prev Build on main (#41952519580)
  • Next Build on main (#41986790434)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc