/* * STABLE: variable structure_type ex1c { * STABLE-NEXT: member base_type unsigned int byte_size(4) encoding(7) a data_member_location(0) , * STABLE-NEXT: member array_type[64] { * STABLE-NEXT: base_type unsigned char byte_size(1) encoding(8) * STABLE-NEXT: } data_member_location(8) * STABLE-NEXT: } byte_size(72)
*/
/* * Example: An ignored field added to an alignment hole
*/
struct ex2a { int a; unsignedlong b; int c; unsignedlong d;
};
/* * STABLE: variable structure_type ex2a { * STABLE-NEXT: member base_type int byte_size(4) encoding(5) a data_member_location(0) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) b data_member_location(8) * STABLE-NEXT: member base_type int byte_size(4) encoding(5) c data_member_location(16) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) d data_member_location(24) * STABLE-NEXT: } byte_size(32)
*/
struct ex2b { int a;
KABI_IGNORE(0, unsignedint n); unsignedlong b; int c; unsignedlong d;
};
_Static_assert(sizeof(struct ex2a) == sizeof(struct ex2b), "ex2a size doesn't match ex2b");
/* * STABLE: variable structure_type ex2b { * STABLE-NEXT: member base_type int byte_size(4) encoding(5) a data_member_location(0) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) b data_member_location(8) * STABLE-NEXT: member base_type int byte_size(4) encoding(5) c data_member_location(16) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) d data_member_location(24) * STABLE-NEXT: } byte_size(32)
*/
struct ex2c { int a;
KABI_IGNORE(0, unsignedint n); unsignedlong b; int c;
KABI_IGNORE(1, unsignedint m); unsignedlong d;
};
_Static_assert(sizeof(struct ex2a) == sizeof(struct ex2c), "ex2a size doesn't match ex2c");
/* * STABLE: variable structure_type ex2c { * STABLE-NEXT: member base_type int byte_size(4) encoding(5) a data_member_location(0) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) b data_member_location(8) * STABLE-NEXT: member base_type int byte_size(4) encoding(5) c data_member_location(16) , * STABLE-NEXT: member base_type [[ULONG]] byte_size(8) encoding(7) d data_member_location(24) * STABLE-NEXT: } byte_size(32)
*/
/* * This may be safe if the structure allocation is managed by the core kernel * and the layout remains unchanged except for appended new members.
*/
KABI_BYTE_SIZE(ex4a, 8);
/* * This may be safe if the structure is fully opaque to modules, even though * its definition has inadvertently become part of the ABI.
*/
KABI_TYPE_STRING( "s#ex5a", "structure_type ex5a { member pointer_type { s#ex4a } byte_size(8) p data_member_location(0) } byte_size(8)");
/* * Make sure the fully expanded type string includes ex4a. * * VERSIONS: ex5a variable structure_type ex5a { * VERSIONS-SAME: member pointer_type { * VERSIONS-SAME: structure_type ex4a { * VERSIONS-SAME: member base_type [[ULONG:long unsigned int|unsigned long]] byte_size(8) encoding(7) a data_member_location(0) * VERSIONS-SAME: } byte_size(8) * VERSIONS-SAME: } byte_size(8) p data_member_location(0) * VERSIONS-SAME: } byte_size(8)
*/
/* * Example: A type string definition for a non-existent type.
*/
struct ex5b { unsignedlong a;
};
/* Replace the type string for struct ex5b */
KABI_TYPE_STRING( "s#ex5b", "structure_type ex5b { member pointer_type { s#ex5c } byte_size(8) p data_member_location(0) } byte_size(8)");
/* Define a type string for a non-existent struct ex5c */
KABI_TYPE_STRING( "s#ex5c", "structure_type ex5c { member base_type int byte_size(4) encoding(5) n data_member_location(0) } byte_size(8)");
/* * Make sure the fully expanded type string includes the definition for ex5c. * * VERSIONS: ex5b variable structure_type ex5b { * VERSIONS-SAME: member pointer_type { * VERSIONS-SAME: structure_type ex5c { * VERSIONS-SAME: member base_type int byte_size(4) encoding(5) n data_member_location(0) * VERSIONS-SAME: } byte_size(8) * VERSIONS-SAME: } byte_size(8) p data_member_location(0) * VERSIONS-SAME: } byte_size(8)
*/
/* * Example: A type string override for a symbol.
*/
KABI_TYPE_STRING("ex6a", "variable s#ex5c");
/* * VERSIONS: ex6a variable structure_type ex5c { * VERSIONS-SAME: member base_type int byte_size(4) encoding(5) n data_member_location(0) * VERSIONS-SAME: } byte_size(8)
*/ #endif/* __KABI_EX_H__ */
Messung V0.5
¤ Dauer der Verarbeitung: 0.13 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.