This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: eliminating null pointer checks on mmu-less machines
- From: Cedric Berger <cedric at berger dot to>
- To: Adam Megacz <adam at megacz dot com>
- Cc: java at gcc dot gnu dot org
- Date: Sat, 13 Sep 2003 10:57:43 +0200
- Subject: Re: eliminating null pointer checks on mmu-less machines
- References: <m13cf1s630.fsf@nowhere.com>
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