对64位Java平台优势 [英] Benefits of 64bit Java platform

查看:129
本文介绍了对64位Java平台优势的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是一个绝对的n00b到Java平台 我想知道是否我需要在我的code能改变什么让64位JRE的好处是什么?

I'm an absolute n00b into the java platform I would like to know whether I need to change anything in my code to get the benefits of 64bit JRE ?

或者是它的东西时,我就开始以java -d64像它会在一些涡轮增压模式下运行?

or is it something like when I initiate it with "java -d64" its gonna run in some turbo mode?

您的帮助是非常AP preciated

Your help is highly appreciated

推荐答案

我的previous版本,而不是虚假的,是很快的书面过于简单化。

My previous version, while not false, was a quickly written oversimplification.

从32到64位的更改不会自动使应用程序运行得更快,它可能会在某些情况下会导致相反的。 在消极的一面 否则取消引用在JVM内存指针可能需要更长的时间与64位指针超过32位。 一个完整的垃圾收集和一个16 GB的堆压缩将很可能需要较长的时间比2 GB的堆。

Changing from 32 to 64 bits will not automatically make your application run faster, it may in some cases lead to the opposite. On the "negative" side Doing de-referencing of memory pointers in the JVM can take a longer time with 64 bit pointers than 32 bit. A full garbage collect and compaction of a 16 GB heap will likely take a longer time than with a 2 GB heap.

在积极的一面: 有64位的处理器指令的,比32位的人更有效。 64位JVM将让你有一个堆大小比大2 ^ 32倍,略显不足,4 GB的一个你可以与32位获得。 (如果你能买得起的RAM量) 有些JVM可以使用COM pressed引用工作,如果你有一个堆大小小于4 GB,让您无需支付64位脱参考价格的64位指令的优势。

On the positive side: There 64 bit processor instructions that are more effective than the 32 bit ones. 64 bit JVM will allow you to have a heap size 2^32 times bigger than the, slightly less than, 4 GB one you can get with 32 bit. (If you can afford to buy that amount of RAM) Some JVMs can work with compressed references if you have a heap size less than 4 GB, giving you the advantage of 64 bit instructions without having to pay the 64 bit de-referencing price.

如果你有一个很好的JVM我会去到64位,无论堆的大小,只是prepared,你可能要采取的性能损失对于具有非常大的堆。

If you have a good JVM I would go to 64 bits no matter the heap size, just be prepared that you may have to take a performance hit for having a really big heap.

这篇关于对64位Java平台优势的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆