Whether a “plain” int bit-field is treated as signed int bit-field or as an unsigned int bit-field (6.7.2, 6.7.2.1).
It is treated as an unsigned int.
Allowable bit-field types other than _Bool, signed int, and unsigned int (6.7.2.1).
A bit field can be declared as any integer type.
Whether a bit-field can straddle a storage-unit boundary (6.7.2.1).
Bit-fields do not straddle storage-unit boundaries.
The order of allocation of bit-fields within a unit (6.7.2.1).
Bit-fields are allocated within a storage unit from high-order to low-order.
The alignment of non-bit-field members of structures (6.7.2.1). This should present no problem unless binary data written by one implementation is read by another.
|
Type |
Alignment Boundary |
Byte Alignment |
|---|---|---|
|
char |
byte |
1 |
|
short |
halfword |
2 |
|
int |
word |
4 |
|
long (SPARC) v8 |
word |
4 |
|
long (SPARC) v9 |
doubleword |
8 |
|
float (SPARC) |
word |
4 |
|
double (SPARC) |
doubleword |
8 |
|
double (x86) |
doubleword |
4 |
|
long double (SPARC) v8 |
doubleword |
8 |
|
long double (x86) |
word |
4 |
|
long double (SPARC) v9 |
quadword |
16 |
|
pointer (SPARC) v8 |
word |
4 |
|
pointer (SPARC) v9 |
quadword |
8 |
|
long long |
doubleword (SPARC) |
8 |
|
long long (x86) |
word |
4 |
|
_Complex |
float |
8 |
|
_Complex |
double |
16 |
|
_Complex |
long double |
32 |
|
_Imaginary |
float |
4 |
|
_Imaginary (SPARC) |
double |
8 |
|
_Imaginary (x86) |
double |
4 |
|
_Imaginary (SPARC) v8 |
long double |
8 |
|
_Imaginary (SPARC) v9 |
long double |
16 |
|
_Imaginary (x86) |
long double |
4 |
The integer type compatible with each enumerated type (6.7.2.2).
This is an int.