liuzqt commented on code in PR #47192:
URL: https://github.com/apache/spark/pull/47192#discussion_r1667112280


##########
core/src/test/scala/org/apache/spark/memory/MemoryManagerSuite.scala:
##########
@@ -335,6 +335,28 @@ private[memory] trait MemoryManagerSuite extends 
SparkFunSuite {
     tMemManager.releaseExecutionMemory(500L, c)
     assert(tMemManager.getMemoryConsumptionForThisTask === 0L)
   }
+
+  test("task peak execution memory usage") {
+    val memoryManager = createMemoryManager(
+      maxOnHeapExecutionMemory = 1000L,
+      maxOffHeapExecutionMemory = 1000L)
+
+    val tMemManager = new TaskMemoryManager(memoryManager, 1)
+    val offHeapConsumer = new TestMemoryConsumer(tMemManager, 
MemoryMode.OFF_HEAP)
+    val onHeapConsumer = new TestMemoryConsumer(tMemManager, 
MemoryMode.ON_HEAP)
+
+    val result1 = Future {

Review Comment:
   I think we don't really need this in term of the semantics of this test 
case. Made it synchronous.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to