avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Efficient htons/swap16 or htonl/swap32 in place?


From: Peter N Lewis
Subject: Re: [avr-gcc-list] Efficient htons/swap16 or htonl/swap32 in place?
Date: Sat, 18 Aug 2001 08:25:47 +0800

At 8:29 +0800 17/8/01, Peter N Lewis wrote:

Is there any way to convince the compiler to generate:

        ldd r20,Y+1
        ldd r21,Y+2
        std Y+1,r21
        std Y+2,r22

No takers for how to do this? I expected there would be lots of efficiency nuts on this list! ;-)

Thanks for any ideas.
   Peter.
PS: Important safety tip - don't allocate 4 32-byte structs, including one on the stack when running on a 4433 with 128 bytes of RAM!
--
<http://www.interarchy.com/>  <ftp://ftp.interarchy.com/interarchy.hqx>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]