On Nov 29 2007 12:04, Kyle McMartin wrote:
>
>For example, if you had 4GB of virtual memory, picture it as an
>array of bytes,
> u8 memory[4096 * (1024 * 1024)]; /* 4G bytes */
uint8_t memory[4096UL * 1024 * 1024];
>Aligned accesses would be accessing this array in this manner,
> u16 memory[(4096 * (1024 * 1024)) / sizeof(u16)] /* 2G bytes */
> u32 memory[(4096 * (1024 * 1024)) / sizeof(u32)] /* 1G bytes */
> u64 memory[(4096 * (1024 * 1024)) / sizeof(u64)] /* 512M bytes */
u64 memory[4096UL * 1024 * 1024 / sizeof(u64)] /* 4G too */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]