[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [lwip-users] Problem With dns.c Using 32-Bit Compilers
From: |
Bill Auerbach |
Subject: |
RE: [lwip-users] Problem With dns.c Using 32-Bit Compilers |
Date: |
Thu, 28 Aug 2008 08:39:30 -0400 |
> > I agree too. Not to use packing would make the code bigger and all
> > compilers have packing, it just a problem of syntax.
>
> In contrast, for most processors, the code gets bigger with structure
> packing! This is because the compiler doesn't know where e.g. (for a
> 32-bit processor) an U32 will be so it has to load every byte of it as
> a single load and combine the 4 bytes in one register. Compared to one
> single load instruction for a correctly aligned U32, this is much
> bigger!
Not all 32-bit processors are code-size affected by non-aligned reads and
writes. PowerPC's and Intel processors for example use the same
instructions for aligned and non-aligned accesses. The accesses may be
slower (quite possibly with caching it's negligible) but the program size
doesn't change.
Bill
- [lwip-users] Problem With dns.c Using 32-Bit Compilers, Nick Thomas, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Jonathan Larmour, 2008/08/27
- RE: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Nick Thomas, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Marek Matej, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Jonathan Larmour, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, address@hidden, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Jonathan Larmour, 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Alain M., 2008/08/27
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Simon Goldschmidt, 2008/08/28
- RE: [lwip-users] Problem With dns.c Using 32-Bit Compilers,
Bill Auerbach <=
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Alain M., 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Michael Williamson, 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, address@hidden, 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Michael Williamson, 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Alain M., 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Jonathan Larmour, 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Alain M., 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Jonathan Larmour, 2008/08/28
- Re: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Alain M., 2008/08/28
- RE: [lwip-users] Problem With dns.c Using 32-Bit Compilers, Tamas Somogyi, 2008/08/29