Whay the main reason we take Jrocket in production mode?
It has below three advantages
(i) Jrockit will give the best performance then sun hotspot,because it has the JIT (just in time) compiler which compile the all the method on startup and convert it to machine to code and save it in the memory which means the same methods called by code wont be compiled again as jrockit will use machine code directly from the memory to run it,so this will increase the performance where as sun jdk doesn't have this option and it compiles and convert the method every it called which is will de-grade the performance on long running JVM's on production.
(ii) Jrockit have the feature called optimization which tracks the history/count of frequently used methods by the code, this feature will optimize those methods automatically to improve the overall system performance,sun JDK doesn't have this future.
(iii) Jrockit has jfr(jrockit filght recorder) which can be used to store/dump of the entire jvm operations for a particular period to narrow down the issues with JVM and its gives very very less overhead to the system and this can be used on production as well witout affecting/degrading the prod JVM performance.
========================================================
Sun JDK uses interpreter (Interpreter and JIT in previous releases) – In this mechanism, the byte code is read and the translated into machine language, but these results are not saved in the memory. So every time even if the same method is run again and again, the JVM has to translate the code into machine language. This means machine code will not be reusable as it is not saved anywhere in the memory.
Oracle JRockit uses only JIT compiler (Just In Time) – JIT mechanism means, once a method is run, the byte code is translated to machine language and this is saved in the memory. This means if the method is run again, there is no need for translation and the machine code is reused.
Because of the interpreter mechanism used by sun jdk, the start up time for the server is faster because it does not have to save the machine code in memory. Once the translation is done for a method, it moves to the other one. Where as oracle JRockit saves the code, which is why start up takes longer. For the same reason, oracle JRockit uses more memory than sun jdk.
In the long run, JRockit gives a slightly better performance as compared to sun jdk.
It has below three advantages
(i) Jrockit will give the best performance then sun hotspot,because it has the JIT (just in time) compiler which compile the all the method on startup and convert it to machine to code and save it in the memory which means the same methods called by code wont be compiled again as jrockit will use machine code directly from the memory to run it,so this will increase the performance where as sun jdk doesn't have this option and it compiles and convert the method every it called which is will de-grade the performance on long running JVM's on production.
(ii) Jrockit have the feature called optimization which tracks the history/count of frequently used methods by the code, this feature will optimize those methods automatically to improve the overall system performance,sun JDK doesn't have this future.
(iii) Jrockit has jfr(jrockit filght recorder) which can be used to store/dump of the entire jvm operations for a particular period to narrow down the issues with JVM and its gives very very less overhead to the system and this can be used on production as well witout affecting/degrading the prod JVM performance.
========================================================
Sun JDK uses interpreter (Interpreter and JIT in previous releases) – In this mechanism, the byte code is read and the translated into machine language, but these results are not saved in the memory. So every time even if the same method is run again and again, the JVM has to translate the code into machine language. This means machine code will not be reusable as it is not saved anywhere in the memory.
Oracle JRockit uses only JIT compiler (Just In Time) – JIT mechanism means, once a method is run, the byte code is translated to machine language and this is saved in the memory. This means if the method is run again, there is no need for translation and the machine code is reused.
Because of the interpreter mechanism used by sun jdk, the start up time for the server is faster because it does not have to save the machine code in memory. Once the translation is done for a method, it moves to the other one. Where as oracle JRockit saves the code, which is why start up takes longer. For the same reason, oracle JRockit uses more memory than sun jdk.
In the long run, JRockit gives a slightly better performance as compared to sun jdk.
No comments:
Post a Comment