J
Jimmy Zhang
hi, I have a couple of questions that I would like someone to take a look,
1. java.lang.Object is the super class for all, does that mean a simple
instantiation of any class
will automatically create a java.lang.Object instance, so any simple object
allocation will create
at least two classes.
2. In Java, if I want to allocate a memory block of 1M, does the JVM have to
ensure the existence
of such memory block, even it has to join and recombine smaller blocks. Is
it more expensive with
a GC enabled language than C/C++
Thanks,
Jimmy
1. java.lang.Object is the super class for all, does that mean a simple
instantiation of any class
will automatically create a java.lang.Object instance, so any simple object
allocation will create
at least two classes.
2. In Java, if I want to allocate a memory block of 1M, does the JVM have to
ensure the existence
of such memory block, even it has to join and recombine smaller blocks. Is
it more expensive with
a GC enabled language than C/C++
Thanks,
Jimmy