reuvenlax opened a new pull request, #41805:
URL: https://github.com/apache/beam/pull/41805

   Reduces per-element overhead in Dataflow worker counter updates:
   
   Counter.setDirty(): Guards the volatile write to commitState behind 
VarHandle.fullFence() and a commitState.get() != DIRTY check, eliminating 
cross-core cache-line write-invalidation traffic when already dirty while 
preventing StoreLoad reordering from stranding updates (e.g., from LongAdder's 
release-only CAS). Documents the thread-safety visibility contract on 
AtomicCounterValue.
   DataflowOutputCounter: Fast-paths concrete single-window WindowedValues 
implementations via exact Class identity in update() and the streaming 
KeyedWorkItem loop, avoiding per-element Collections.singletonList allocations 
from getWindows() and JDK-8180450 _secondary_super_cache contention across 
worker threads.
   Adds concurrency stress tests (including a release-only CAS counter) in 
CounterTest and fast-path/fallback/rejection tests in DataflowOutputCounterTest.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to