3 out of 26 rated this helpful - Rate this topic

Structure Alignment Examples 

The following represent a set of examples showing structure requirements.

Example 1

AMDConversionExample1 graphic

Example 2

struct
{   // size = 24 bytes, alignment = Quadword
   int a;
   double b;
   short c;
};
AMD Conversion Example graphic

Example 3

AMD Conversion Example3 graphic

Example 4

AMDConversionExample4 graphic

Reference

Types and Storage

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ
Example 4
Example 4 should indicate that l uses bytes 0-4, not 4-7.

Actually, that should be "0-3" that l uses, not "0-4"
Advertisement