+#define __type_integer(_type, _byte_order, _base, _encoding) \
+ { \
+ .atype = atype_integer, \
+ .u.basic.integer = \
+ { \
+ .size = sizeof(_type) * CHAR_BIT, \
+ .alignment = ltt_alignof(_type) * CHAR_BIT, \
+ .signedness = is_signed_type(_type), \
+ .reverse_byte_order = _byte_order != __BYTE_ORDER, \
+ .base = _base, \
+ .encoding = lttng_encode_##_encoding, \
+ }, \
+ } \
+
+struct lttng_integer_type {
+ unsigned int size; /* in bits */
+ unsigned short alignment; /* in bits */
+ unsigned int signedness:1;
+ unsigned int reverse_byte_order:1;
+ unsigned int base; /* 2, 8, 10, 16, for pretty print */
+ enum lttng_string_encodings encoding;
+};
+
+union _lttng_basic_type {
+ struct lttng_integer_type integer;
+ struct {
+ const char *name;
+ } enumeration;
+ struct {
+ enum lttng_string_encodings encoding;
+ } string;
+};
+
+struct lttng_basic_type {
+ enum abstract_types atype;
+ union {
+ union _lttng_basic_type basic;
+ } u;