可以看下面的文档: https://spoddutur.github.io/spark-notes/distribution_of_executors_cores_and_memory_for_spark_application.html