Maximum size of MappedByteBuffer in Java 5.0 64 bit

  • Thread starter The POWER of 2WO
  • Start date
T

The POWER of 2WO

I have developed a spatial database that accesses its tablespaces via
MappedByteBuffers. As these tablespaces are growing, I'm near the 2Gig limit
imposed by Java 1.4.2_06.

I am investigating if I can alleviate this limit by using Java 5.0 with 64
bit Linux.

My question is as follows:

what is the largest ByteBuffer I can allocate in Java 5.0 64 bit Linux
edition? I know that Linux 64 bit edition supports 512G virtual space per
process. Can Java 5.0 utilize all 512G virtual space, and if so, how much
for ByteBuffers ?

If Java 5.0 can allocate only 2G ByteBuffers, can it allocate a pool of
ByteBuffers, whose sum is 512G ?

Thankyou
Kevin M
Canadian Demographic Mapping Service
http://69.194.236.224:18080

Replies either to this group or to publicgis_d AT rogers DOT com
 
B

Boudewijn Dijkstra

If Java 5.0 can allocate only 2G ByteBuffers, can it allocate a pool
of ByteBuffers, whose sum is 512G ?

Probably. But note that a ByteBuffer may be larger than 2G, but the standard
ones are implemented as a single array. Arrays are limited to 31-bit indices.
 
X

xarax

Boudewijn Dijkstra said:
Probably. But note that a ByteBuffer may be larger than 2G, but the standard
ones are implemented as a single array. Arrays are limited to 31-bit indices.

You can use scattering and gathering buffers to
exceed the 2GB limit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top