From 44c7c62bcfca74c82ffc4e3c53997fff47bfacac Mon Sep 17 00:00:00 2001 From: Eric Liang Date: Wed, 6 Jul 2016 16:30:25 -0700 Subject: [SPARK-16021] Fill freed memory in test to help catch correctness bugs ## What changes were proposed in this pull request? This patches `MemoryAllocator` to fill clean and freed memory with known byte values, similar to https://github.com/jemalloc/jemalloc/wiki/Use-Case:-Find-a-memory-corruption-bug . Memory filling is flag-enabled in test only by default. ## How was this patch tested? Unit test that it's on in test. cc sameeragarwal Author: Eric Liang Closes #13983 from ericl/spark-16021. --- project/SparkBuild.scala | 1 + 1 file changed, 1 insertion(+) (limited to 'project') diff --git a/project/SparkBuild.scala b/project/SparkBuild.scala index b1a9f39342..c769ba300e 100644 --- a/project/SparkBuild.scala +++ b/project/SparkBuild.scala @@ -825,6 +825,7 @@ object TestSettings { javaOptions in Test += "-Dspark.testing=1", javaOptions in Test += "-Dspark.port.maxRetries=100", javaOptions in Test += "-Dspark.master.rest.enabled=false", + javaOptions in Test += "-Dspark.memory.debugFill=true", javaOptions in Test += "-Dspark.ui.enabled=false", javaOptions in Test += "-Dspark.ui.showConsoleProgress=false", javaOptions in Test += "-Dspark.unsafe.exceptionOnMemoryLeak=true", -- cgit v1.2.3