mridulm commented on code in PR #36665: URL: https://github.com/apache/spark/pull/36665#discussion_r886246382
########## core/src/main/scala/org/apache/spark/scheduler/TaskResultGetter.scala: ########## @@ -102,6 +102,10 @@ private[spark] class TaskResultGetter(sparkEnv: SparkEnv, scheduler: TaskSchedul (deserializedResult, size) } + // quickly return if the task has finished + if (scheduler.isFinishedTask(taskSetManager, tid)) { + return Review Comment: Agree with @Ngone51, this is something which is checked below (in `handleSuccessfulTask`) - the potential improvement, for an unlikely corner case, is not worth the additional complexity. -- 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: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org