Github user zsxwing commented on a diff in the pull request:
https://github.com/apache/spark/pull/5136#discussion_r27018077
--- Diff:
core/src/main/scala/org/apache/spark/storage/DiskBlockManager.scala ---
@@ -91,7 +90,12 @@ private[spark] class DiskBlockManager(blockManager:
BlockManager, conf: SparkCon
/** List all the files currently stored on disk by the disk manager. */
def getAllFiles(): Seq[File] = {
// Get all the files inside the array of array of directories
- subDirs.flatten.filter(_ != null).flatMap { dir =>
+ subDirs.flatMap { dir =>
--- End diff --
If `a` is not `volatile`, actually, `a` can be something else. E.g.,
Thread 1 call `foo`. It creates "foobar" on address 0x1234, then assign
0x1234 to `a`. However, these update will exist in the current CPU cache, then
flush to the memory. It's possible only `a = 0x1234` has been updated to the
memory, but the content in address 0x1234 is still in the current CPU cache.
Then Thread 2 may see `a` is `0x1234` and also see the old content of address
`0x1234`, which is an uninitialized String.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]