tags:

views:

107

answers:

3

Hi, I read something like pointer must be byte-aligned. My understanding in a typical 32bit architecture... all pointers are byte aligned...No ?

Please confirm.

can there be a pointer which is not byte-aligned ?

Basically this is mentioned in a hardware reference manual for tx descriptor memory.

+8  A: 

Yes, you cannot address any amount of memory smaller than a byte.

fmark
+1  A: 

If a pointer or a number is not byte aligned, it would start in the middle of a byte. I.e. some bits of a byte would belong to one pointer, and other bits to another. This would be strange and it does not occur in practice.

Sjoerd
not 'does not occur' cannot occur because a byte is the smallest addressable unit...
Spudd86
+5  A: 
Pete Kirkham
+1 for the dagger and/for the note
ShinTakezou