Subject: Re: Data Abort Exceptions
To: None <Richard.Earnshaw@arm.com>
From: Jay Monkman <jtm@smoothsmoothie.com>
List: port-arm
Date: 07/22/2002 13:38:41
On Mon, Jul 22, 2002 at 05:48:56PM +0100, Richard Earnshaw wrote:
> Current releases of NetBSD are configured not to abort the above, but to
> use a load-and-rotate type of operation, so in the above func2 would print
> the value contained by loading (*p & ~3) rotated by 8 bits.
How do you make the compiler generate code to do that? I've looked
through GCC's documentation, and haven't found it, nor have I found
the where it's set up in NetBSD.
> On ELF builds we've outlawed this, and on processors that support faulting
> unaligned accesses we will probably make the CPU abort the access (though
> I don't believe we do so yet).
On ELF, will you have an exception handler that looks at the aborted
instrcution, basically interprets it? I believe that's how Linux does
it, although I didn't look closely. Or will you just kill the process
that does it?
Thanks for the help.
--
Jay Monkman The truth knocks on the door and you say "Go away, I'm
looking for the truth," and so it goes away. Puzzling.
- from _Zen_and_the_Art_of_Motorcycle_Maintenance_