ts-7000
[Top] [All Lists]

Re: [ts-7000] Re: pointer weirdness

To:
Subject: Re: [ts-7000] Re: pointer weirdness
From: Oliver Martin <>
Date: Wed, 12 Sep 2007 21:30:26 +0200
David Hawkins schrieb:
> Hi Yan,
> 
>> The one thing that puzzles me is that 32-bit access
>> on a 16-bit boundary works fine....  I guess I
>> don't understand the ARM hardware as well as I should.
> 
> I think the results of this type of access is
> device specific, eg. some ARM registers say that
> only 32-bit access is allowed. I think in general
> though if you do an unaligned address read, it'll
> return the right value, even if the hardware hides
> the fact that it actually had to perform two reads
> to get the data for you.
> 
Unaligned 32-bit reads are rotated right by the number of bytes they are
unaligned, so if they seem to work, it must be gcc doing some trickery
(though I can only imagine this if the address is known at compile
time). The hardware definitely doesn't do any magic for you.
For unaligend 32-bit stores, the address is truncated by masking the two
least significant bits away.


 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU