Uh oh!
There was an error while loading. Please reload this page.
[SPARK-7288] Suppress compiler warnings due to use of sun.misc.Unsafe; add facade in front of Unsafe; remove use of Unsafe.setMemory - #5814
Conversation
JoshRosen
commented
Apr 30, 2015
rxin
commented
Apr 30, 2015
Maybe you've already figured it out, but is it possible to suppress warning only for the unsafe module? |
tgravescs
commented
Apr 30, 2015
trying it out |
JoshRosen
commented
Apr 30, 2015
Won't we get warnings in other modules that call |
JoshRosen
commented
Apr 30, 2015
I think that we'll be able to restrict this compiler flag to the |
tgravescs
commented
Apr 30, 2015
it built fine for me with jdk6 and this patch. |
JoshRosen
commented
Apr 30, 2015
Also checking to see whether I need to change unidoc compiler options... |
JoshRosen
commented
Apr 30, 2015
Alright, pushed a new commit that puts a facade in front of Unsafe and reduced the scope of the compiler flag to only affect the |
SparkQA
commented
Apr 30, 2015
Test build #31442 has finished for PR 5814 at commit
|
JoshRosen
commented
Apr 30, 2015
When I ran my one of my aggregation hash map benchmarks with |
rxin
commented
Apr 30, 2015
LGTM. |
SparkQA
commented
Apr 30, 2015
Test build #31447 has finished for PR 5814 at commit
|
…; add facade in front of Unsafe; remove use of Unsafe.setMemory This patch suppresses compiler warnings due to our use of `sun.misc.Unsafe` (introduced in apache#5725). These warnings can only be suppressed via the `-XDignore.symbol.file` javac flag; the `SuppressWarnings` annotation won't work for these. In order to restrict uses of this compiler flag to the `unsafe` module, I placed a facade in front of `Unsafe` so that other modules won't call it directly. This facade also will also help us to avoid accidental usage of deprecated Unsafe methods or methods that aren't supported in Java 6. I also removed an unnecessary use of `Unsafe.setMemory`, which isn't present in certain versions of Java 6, and excluded the new `unsafe` module from Javadoc. Author: Josh Rosen <joshrosen@databricks.com> Closesapache#5814 from JoshRosen/unsafe-compiler-warnings-fixes and squashes the following commits: 9e8c483 [Josh Rosen] Exclude new unsafe module from Javadoc ba75ecf [Josh Rosen] Only apply -XDignore.symbol.file flag in unsafe project. 7403345 [Josh Rosen] Put facade in front of Unsafe. 50230c0 [Josh Rosen] Remove usage of Unsafe.setMemory 96d41c9 [Josh Rosen] Use -XDignore.symbol.file to suppress warnings about sun.misc.Unsafe usage
…; add facade in front of Unsafe; remove use of Unsafe.setMemory This patch suppresses compiler warnings due to our use of `sun.misc.Unsafe` (introduced in apache#5725). These warnings can only be suppressed via the `-XDignore.symbol.file` javac flag; the `SuppressWarnings` annotation won't work for these. In order to restrict uses of this compiler flag to the `unsafe` module, I placed a facade in front of `Unsafe` so that other modules won't call it directly. This facade also will also help us to avoid accidental usage of deprecated Unsafe methods or methods that aren't supported in Java 6. I also removed an unnecessary use of `Unsafe.setMemory`, which isn't present in certain versions of Java 6, and excluded the new `unsafe` module from Javadoc. Author: Josh Rosen <joshrosen@databricks.com> Closesapache#5814 from JoshRosen/unsafe-compiler-warnings-fixes and squashes the following commits: 9e8c483 [Josh Rosen] Exclude new unsafe module from Javadoc ba75ecf [Josh Rosen] Only apply -XDignore.symbol.file flag in unsafe project. 7403345 [Josh Rosen] Put facade in front of Unsafe. 50230c0 [Josh Rosen] Remove usage of Unsafe.setMemory 96d41c9 [Josh Rosen] Use -XDignore.symbol.file to suppress warnings about sun.misc.Unsafe usage
…; add facade in front of Unsafe; remove use of Unsafe.setMemory This patch suppresses compiler warnings due to our use of `sun.misc.Unsafe` (introduced in apache#5725). These warnings can only be suppressed via the `-XDignore.symbol.file` javac flag; the `SuppressWarnings` annotation won't work for these. In order to restrict uses of this compiler flag to the `unsafe` module, I placed a facade in front of `Unsafe` so that other modules won't call it directly. This facade also will also help us to avoid accidental usage of deprecated Unsafe methods or methods that aren't supported in Java 6. I also removed an unnecessary use of `Unsafe.setMemory`, which isn't present in certain versions of Java 6, and excluded the new `unsafe` module from Javadoc. Author: Josh Rosen <joshrosen@databricks.com> Closesapache#5814 from JoshRosen/unsafe-compiler-warnings-fixes and squashes the following commits: 9e8c483 [Josh Rosen] Exclude new unsafe module from Javadoc ba75ecf [Josh Rosen] Only apply -XDignore.symbol.file flag in unsafe project. 7403345 [Josh Rosen] Put facade in front of Unsafe. 50230c0 [Josh Rosen] Remove usage of Unsafe.setMemory 96d41c9 [Josh Rosen] Use -XDignore.symbol.file to suppress warnings about sun.misc.Unsafe usage
This patch suppresses compiler warnings due to our use of
sun.misc.Unsafe(introduced in #5725). These warnings can only be suppressed via the-XDignore.symbol.filejavac flag; the@SuppressWarningsannotation won't work for these.In order to restrict uses of this compiler flag to the
unsafemodule, I placed a facade in front ofUnsafeso that other modules won't call it directly. This facade also will also help us to avoid accidental usage of deprecated Unsafe methods or methods that aren't supported in Java 6.I also removed an unnecessary use of
Unsafe.setMemory, which isn't present in certain versions of Java 6, and excluded the newunsafemodule from Javadoc.