This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: eliminating null pointer checks on mmu-less machines


Adam Megacz wrote:

Hey, I was thinking about NullPointerException handling on machines
with no MMU.  There's not much that can be done for field accesses,
but method invocations are much more common.

Is it feasible to place an object at address 0x0

Short answer: No in 90% of the cases.
Processors often have special stuff at physical address 0, like internal
registers, trap vectors and such.
It could be possible to redefine NULL to be something different
from 0. I've no idea how expensive that would be, but I suspect
it is very expensive.
Cedric



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]