Name: nt126004 Date: 08/27/2001
% java -version
java version "1.4.0-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta-b65)
Java HotSpot(TM) Client VM (build 1.4.0-beta-b65, mixed mode)
java.nio.Buffer may have problems with 64bit environments. Many methods
like |capacity| (see
http://puck.informatik.med.uni-giessen.de/java/j2sdk1_4_docs/api/java/nio/Buffer.html#capacity())
return an |int| (or take |int| as a position argument for buffer position - like
|Buffer position(int newPosition)|) - which is 32bit.
But on sparcv9 it may have 64bits (sparcv9 binaries can mmap() files larger than
4GB into process address space), e.g. |long| should be used instead.
This looks pretty urgend as JDK 1.4 is currently in _BETA_-status...
this bug should not be shipped with the FCS version...
BTW: unfortunatley this isn't the only place where JAVA runns into this
32bit vs. 64bit issue... the whole JAVA API needs to be reviewed for
such issues... ;-((
(Review ID: 130656)
======================================================================
% java -version
java version "1.4.0-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta-b65)
Java HotSpot(TM) Client VM (build 1.4.0-beta-b65, mixed mode)
java.nio.Buffer may have problems with 64bit environments. Many methods
like |capacity| (see
http://puck.informatik.med.uni-giessen.de/java/j2sdk1_4_docs/api/java/nio/Buffer.html#capacity())
return an |int| (or take |int| as a position argument for buffer position - like
|Buffer position(int newPosition)|) - which is 32bit.
But on sparcv9 it may have 64bits (sparcv9 binaries can mmap() files larger than
4GB into process address space), e.g. |long| should be used instead.
This looks pretty urgend as JDK 1.4 is currently in _BETA_-status...
this bug should not be shipped with the FCS version...
BTW: unfortunatley this isn't the only place where JAVA runns into this
32bit vs. 64bit issue... the whole JAVA API needs to be reviewed for
such issues... ;-((
(Review ID: 130656)
======================================================================
- duplicates
-
JDK-8180628 (bf) Retrofit direct buffer support for size beyond gigabyte scales
-
- Closed
-
-
JDK-4646618 Please permit Buffer.position(long newPosition) instead of int
-
- Closed
-
-
JDK-5103372 (bf) Allow larger size of NIO buffer space (greater than ~2047 MB)
-
- Closed
-
-
JDK-6200448 (bf) Can't allocate ByteBuffers over 2 GBytes
-
- Closed
-
- relates to
-
JDK-6347833 (fs) Enhance MappedByteBuffer to support sizes >2GB on 64 bit platforms
-
- Closed
-