-
Bug
-
Resolution: Cannot Reproduce
-
P2
-
None
-
1.1.7
-
None
-
generic
-
solaris_2.4
Apparently, Object Serialization throws an internal error when trying
to deserialize a large array. The size at which this error is thrown
increases with an increase in the max size of the heap the JVM is
started with.
The program traced below merely writes out on an ObjectOutputStream
(built atop a socket) an object which happens to be an int[] of size
controlled by the command line parameter; the process on the other
side attempts to read it in. There is no difficulty in achieving this
for arrays of size upto 1M. At 1.5M and above I start getting some
internal error being thrown.
denali.research.att.com% java Matrix.smi.examples.PingClient 1000000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381264139.
Stopped rmi at 904381279091.
Result: true
...done
denali.research.att.com% java Matrix.smi.examples.PingClient 2000000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381657297.
java.lang.NullPointerException
at java.io.ObjectInputStream.inputArray(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java)
at java.io.ObjectInputStream.inputObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at Matrix.smi.ObjectStreamReader.read(ObjectStreamReader.java:44)
at Matrix.smi.Connection.read(Connection.java:93)
at Matrix.smi.Session.read(Session.java:302)
at Matrix.smi.Session$1.run(Session.java:95)
^C
denali.research.att.com% denali.research.att.com% java
Matrix.smi.examples.PingClient 1500000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381699373.
java.lang.NullPointerException
at java.io.ObjectInputStream.inputArray(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java)
at java.io.ObjectInputStream.inputObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at Matrix.smi.ObjectStreamReader.read(ObjectStreamReader.java:44)
at Matrix.smi.Connection.read(Connection.java:93)
at Matrix.smi.Session.read(Session.java:302)
at Matrix.smi.Session$1.run(Session.java:95)
^C
denali.research.att.com% denali.research.att.com%
to deserialize a large array. The size at which this error is thrown
increases with an increase in the max size of the heap the JVM is
started with.
The program traced below merely writes out on an ObjectOutputStream
(built atop a socket) an object which happens to be an int[] of size
controlled by the command line parameter; the process on the other
side attempts to read it in. There is no difficulty in achieving this
for arrays of size upto 1M. At 1.5M and above I start getting some
internal error being thrown.
denali.research.att.com% java Matrix.smi.examples.PingClient 1000000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381264139.
Stopped rmi at 904381279091.
Result: true
...done
denali.research.att.com% java Matrix.smi.examples.PingClient 2000000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381657297.
java.lang.NullPointerException
at java.io.ObjectInputStream.inputArray(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java)
at java.io.ObjectInputStream.inputObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at Matrix.smi.ObjectStreamReader.read(ObjectStreamReader.java:44)
at Matrix.smi.Connection.read(Connection.java:93)
at Matrix.smi.Session.read(Session.java:302)
at Matrix.smi.Session$1.run(Session.java:95)
^C
denali.research.att.com% denali.research.att.com% java
Matrix.smi.examples.PingClient 1500000
Starting client...
Should print [I@1dce09ae.
Started rmi at 904381699373.
java.lang.NullPointerException
at java.io.ObjectInputStream.inputArray(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java)
at java.io.ObjectInputStream.inputObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java)
at Matrix.smi.ObjectStreamReader.read(ObjectStreamReader.java:44)
at Matrix.smi.Connection.read(Connection.java:93)
at Matrix.smi.Session.read(Session.java:302)
at Matrix.smi.Session$1.run(Session.java:95)
^C
denali.research.att.com% denali.research.att.com%
- relates to
-
JDK-4138089 return value of ArrayAlloc should be checked to see if null was returned
-
- Closed
-