kezhuw commented on a change in pull request #15246:
URL: https://github.com/apache/flink/pull/15246#discussion_r595425459
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/memory/MemoryManager.java
##########
@@ -341,7 +340,7 @@ private MemorySegment releaseSegmentsForOwnerUntilNextOwner(
MemorySegment firstSeg, Iterator<MemorySegment> segmentsIterator) {
AtomicReference<MemorySegment> nextOwnerMemorySegment = new
AtomicReference<>();
Object owner = firstSeg.getOwner();
- allocatedSegments.compute(
+ allocatedSegments.computeIfPresent(
Review comment:
I guess `segment.isFreed()` in the loop is misleading and not necessary
now.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]