You are here : Home / Core Java Tutorials / Series of JVM and Garbage Collection (GC) in java - Best explanations ever
In this tutorial we will learn how to use -Xverify option in java. And how to speed up eclipse.
Contents of page >
- 1) What is purpose of using -Xverify option?
- 2) Using -Xverify with different parameters >
- -Xverify:remote
- -Xverify:all
- -Xverify:none
- 3) What happens if you don’t pass any option to -Xverify ? What is default value of -Xverify ?
- 4) How -Xverify can speed up eclipse ?
- 5) Should you use -Xverify:<none> in production environment?
1) What is purpose of using -Xverify option?
-Xverify option manually verifies the correctness of the bytecode at the time when java classes are loaded.
-Xverify option helps us in improving the efficiency of classes at runtime.
2) Using -Xverify with different parameters >
- -Xverify:remote - It will Verify only those java classes loaded over network.
- -Xverify:all - It will verify bytecode of all java classes.
- -Xverify:none - It will not verify bytecode of any java class.
3) What happens if you don’t pass any option to -Xverify ? What is default value of -Xverify ?
Default value of -Xverify option is remote.
So -Xverify:<remote> will be used at runtime by default.
So, if you don’t pass any option to -Xverify. It will Verify only those those java classes loaded over network.
4) How -Xverify can speed up eclipse ?
As -Xverify:none will not verify bytecode of any java class, it will help in speeding up eclipse.
Example >
E:\>java -Xverify:none MyJavaProgram
This is my first Java Program
E:\>
|
5) Should you use -Xverify:<none> in production environment?
No, we must not use -Xverify:<none> in production because in that case bytecode of any class will not be verified and might lead to some serious security issues.
Class Loader Subsystem of JVM is used to load class files. Classloader verifies the class file using byte code verifier. Class file will only be loaded if it is valid. So, making any changes to default class loading process is NOT advisable.
Summary -
So in this core java tutorial we learned What is purpose of using -Xverify option? How to use -Xverify with different parameters. What happens if you don’t pass any option to -Xverify ? What is default value of -Xverify ? How -Xverify can speed up eclipse ? Should you use -Xverify:<none> in production or not?
Having any doubt? or you liked the tutorial! Please comment in below section.
Please express your love by liking JavaMadeSoEasy.com (JMSE) on facebook, following on google+ or Twitter.
RELATED LINKS>