I saw Java -server in http://shootout.alioth.debian.org/ for programming language benchmark. I know that -server is a parameter for running JVM. I want to know:
When we use -server parameter and how it work? Can we use this parameter for java desktop application?
thanks.
You can change the parameters passed to the JVM in the Arguments tab in the VM Arguments box. That configuration can then be used as the default when running the project.
Java Virtual Machine, or JVM, loads, verifies and executes Java bytecode. It is known as the interpreter or the core of Java programming language because it executes Java programming.
The JVM consists of three distinct components: Class Loader. Runtime Memory/Data Area. Execution Engine.
There are three types of options that you can add to your JVM, standard, non-standard and advanced options. If you apply an advanced option, you always precede the option with -XX: . Similarly if you're using a non-standard option, you'll use -X . Standard options don't prepend anything to the option.
It just selects the "Server Hotspot VM". See documentation (Solaris/Linux) for java
.
According to Wikipedia:
Sun's JRE features 2 virtual machines, one called Client and the other Server. The Client version is tuned for quick loading. It makes use of interpretation, compiling only often-run methods. The Server version loads more slowly, putting more effort into producing highly optimized JIT compilations, that yield higher performance.
See: http://en.wikipedia.org/wiki/HotSpot
The -server flag will indicate to the launcher that the hw is a server class machine which for java 6 means at least 2 cores and at least 2 GB physical memory (ie most machines these days). On server class machines the deafult selection is
Note that on 32 bit windows there is no server vm so the client vm is the default. On the other 32 bit machines the server vm is chosen if the hw is server class, otherwise it's client. On 64 bit machines there is no client vm so the server vm is the default.
A link to the hot spot faq: HotSpot
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With