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

ben-manes / caffeine / #4881 / 1
100%
master: 100%

Build:
DEFAULT BRANCH: master
Ran 28 May 2025 11:21AM UTC
Files 78
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

28 May 2025 09:42AM UTC coverage: 99.948%. Remained the same
#4881.1

push

github

ben-manes
Use stronger memory order to avoid publication races (fixes #1820)

TSAN detected a theoretical race for a weak valued cache during a #put
call. This can happen on a weak memory model like aarch64 if it also
aggressively reorders. Tracing with Charles Munger (Google), we decided
that the key and value should use acquire semantics and opaque
elsewhere to document the intentions. However this was based on logical
reasoning of our understandings of the memory models, as we could not
reproduce the results to determine if it was a true or false positive.
The TSAN issue pointed to the WeakReference constructor accepting the
key reference as a plain field and being read as one, which should be
benign race as either the user's or a sentinel value.

On a 14-core M3 Max, under heavy load the existing test
Issue568Test#intermittentNull() fails due to incorrectly observing a
null value. The additional multi-threaded test cases incur enough load
to trigger this on this machine. The CircleCI arm64 instance does not
aggressive recorder enough or offer enough concurrency to expose this
race. This is different from the TSAN issue, but highlights the same
fundamental flaw.

Release semantics only apply to the field itself and does not provide
a strong enough happens-before edge for the newly constructed object
for its publication to be complete. A volatile fence is required in
this case since the fields are non-final.

7730 of 7734 relevant lines covered (99.95%)

1.0 hits per line

Source Files on job #4881.1
  • Tree
  • List 78
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 4881
  • 786d1c85 on github
  • Prev Job for on master (##4879.1)
  • Next Job for on master (##4886.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