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

stillwater-sc / universal / 37004798671
88%
master: 84%

Build:
Build:
LAST BUILD BRANCH: perf/issue-1802-fma-hypot-limbs
DEFAULT BRANCH: master
Ran 02 Oct 2026 12:43PM UTC
Jobs 1
Files 677
Run time 3min
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

02 Oct 2026 12:06PM UTC coverage: 86.024% (+0.005%) from 86.019%
37004798671

push

github

web-flow
fix(takum): round + - * / and fma once, not twice through a double (#1621)

Narrow takums evaluated arithmetic in a double and converted back, which
rounds twice: to 53 bits, then to the takum. That is harmless only when
53 >= 2s + 2 for an s-bit significand (Figueroa), i.e. nbits <= 26 + rbits,
29 for rbits = 3. takum<30,3> through takum<57,3> were exposed:
takum<32,3> 0x44000001 * 0x40000001 gave 0x44000002, where the correctly
rounded product is 0x44000003. The gate now reads
2 * (maxCharBits + 1) + 2 > 53, so those widths take the exact integer path
(takum_wide_arithmetic.hpp) that takum<64,3> already used.

fma was worse, and at every width. std::fma rounds to double before the
takum rounding, and no width makes that safe: when a*b is exactly a takum
midpoint and c is tiny, the double drops c and the tie goes to even instead
of to c's side. takum<16,3> fma(a, b, minpos) was wrong for 2822 of the
5648 operand pairs in [1,2) whose product is a midpoint -- below the new
gate, so moving it would not have helped. fma now takes the exact path at
every width.

Tests: random sampling does not find these (0 in 10^8 pairs for
takum<32,3>), so wide_arithmetic.cpp now constructs them and checks them
against its exact 1024-bit reference, at regression level 1:
  near-midpoint products, takum<32,3> and takum<40,3> (with the issue's
  three quoted products)          756 / 789 wrong before, 0 now
  fma midpoint + tiny, takum<16,3> and takum<32,3>
                                  866 / 2000 wrong before, 0 now
The binary-op and fma reference checks are factored out of their sweeps
so the constructed cases reuse them unchanged. All four regression levels
of wide_arithmetic pass, as does the takum and takum_log suite.

Cost on an Apple M-series, takum<32,3>: add 77 -> 98 ns, mul 81 -> 47 ns,
div 69 -> 203 ns, fma 130 -> 91 ns; takum<16,3> fma 120 -> 107 ns.

Still open from #1616: sqrt is double-rounded the same way and has no
integer path yet, and to_ieee754<floa... (continued)

6 of 6 new or added lines in 1 file covered. (100.0%)

45621 of 53033 relevant lines covered (86.02%)

9705198.5 hits per line

Jobs
ID Job ID Ran Files Coverage
1 37004798671.1 02 Oct 2026 12:43PM UTC 677
86.02
GitHub Action Run
Source Files on build 37004798671
  • Tree
  • List 677
  • Changed 10
  • Source Changed 9
  • Coverage Changed 6
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #37004798671
  • e9a45bd3 on github
  • Prev Build on main (#36950912693)
  • Next Build on main (#37004688316)
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