lib: merge common CTF IR part with the remaining implementation
[babeltrace.git] / lib / ctf-ir / field-types.c
index 4e808b938e5faa22072af00dbb7d2eea080d1b85..5de2978f814c9b93ad66672a2421c51d6572b38f 100644 (file)
@@ -79,76 +79,183 @@ struct bt_field_type *bt_field_type_sequence_copy_recursive(
 static
 struct bt_field_type *bt_field_type_string_copy(struct bt_field_type *ft);
 
-static struct bt_field_type_common_methods bt_field_type_integer_methods = {
-       .freeze = bt_field_type_common_generic_freeze,
-       .validate = bt_field_type_common_integer_validate,
-       .set_byte_order = bt_field_type_common_integer_set_byte_order,
-       .copy = (bt_field_type_common_method_copy)
+static
+int bt_field_type_integer_validate(struct bt_field_type *ft);
+
+static
+int bt_field_type_enumeration_validate_recursive(
+               struct bt_field_type *ft);
+static
+int bt_field_type_sequence_validate_recursive(
+               struct bt_field_type *ft);
+static
+int bt_field_type_array_validate_recursive(
+               struct bt_field_type *ft);
+static
+int bt_field_type_structure_validate_recursive(
+               struct bt_field_type *ft);
+static
+int bt_field_type_variant_validate_recursive(
+               struct bt_field_type *ft);
+
+static
+void bt_field_type_generic_freeze(struct bt_field_type *ft);
+
+static
+void bt_field_type_enumeration_freeze_recursive(
+               struct bt_field_type *ft);
+static
+void bt_field_type_structure_freeze_recursive(
+               struct bt_field_type *ft);
+static
+void bt_field_type_variant_freeze_recursive(
+               struct bt_field_type *ft);
+static
+void bt_field_type_array_freeze_recursive(
+               struct bt_field_type *ft);
+static
+void bt_field_type_sequence_freeze_recursive(
+               struct bt_field_type *ft);
+
+static
+void bt_field_type_integer_set_byte_order(
+               struct bt_field_type *ft, enum bt_byte_order byte_order);
+
+static
+void bt_field_type_enumeration_set_byte_order_recursive(
+               struct bt_field_type *ft, enum bt_byte_order byte_order);
+
+static
+void bt_field_type_floating_point_set_byte_order(
+               struct bt_field_type *ft, enum bt_byte_order byte_order);
+
+static
+void bt_field_type_structure_set_byte_order_recursive(
+               struct bt_field_type *ft,
+               enum bt_byte_order byte_order);
+static
+void bt_field_type_variant_set_byte_order_recursive(
+               struct bt_field_type *ft,
+               enum bt_byte_order byte_order);
+
+static
+void bt_field_type_array_set_byte_order_recursive(
+               struct bt_field_type *ft,
+               enum bt_byte_order byte_order);
+
+static
+void bt_field_type_sequence_set_byte_order_recursive(
+               struct bt_field_type *ft,
+               enum bt_byte_order byte_order);
+
+static
+int bt_field_type_integer_compare(struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_floating_point_compare(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_enumeration_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_string_compare(struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_structure_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_variant_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_array_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static
+int bt_field_type_sequence_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b);
+
+static struct bt_field_type_methods bt_field_type_integer_methods = {
+       .freeze = bt_field_type_generic_freeze,
+       .validate = bt_field_type_integer_validate,
+       .set_byte_order = bt_field_type_integer_set_byte_order,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_integer_copy,
-       .compare = bt_field_type_common_integer_compare,
+       .compare = bt_field_type_integer_compare,
 };
 
-static struct bt_field_type_common_methods bt_field_type_floating_point_methods = {
-       .freeze = bt_field_type_common_generic_freeze,
+static struct bt_field_type_methods bt_field_type_floating_point_methods = {
+       .freeze = bt_field_type_generic_freeze,
        .validate = NULL,
-       .set_byte_order = bt_field_type_common_floating_point_set_byte_order,
-       .copy = (bt_field_type_common_method_copy)
+       .set_byte_order = bt_field_type_floating_point_set_byte_order,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_floating_point_copy,
-       .compare = bt_field_type_common_floating_point_compare,
+       .compare = bt_field_type_floating_point_compare,
 };
 
-static struct bt_field_type_common_methods bt_field_type_enumeration_methods = {
-       .freeze = bt_field_type_common_enumeration_freeze_recursive,
-       .validate = bt_field_type_common_enumeration_validate_recursive,
-       .set_byte_order = bt_field_type_common_enumeration_set_byte_order_recursive,
-       .copy = (bt_field_type_common_method_copy)
+static struct bt_field_type_methods bt_field_type_enumeration_methods = {
+       .freeze = bt_field_type_enumeration_freeze_recursive,
+       .validate = bt_field_type_enumeration_validate_recursive,
+       .set_byte_order = bt_field_type_enumeration_set_byte_order_recursive,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_enumeration_copy_recursive,
-       .compare = bt_field_type_common_enumeration_compare_recursive,
+       .compare = bt_field_type_enumeration_compare_recursive,
 };
 
-static struct bt_field_type_common_methods bt_field_type_string_methods = {
-       .freeze = bt_field_type_common_generic_freeze,
+static struct bt_field_type_methods bt_field_type_string_methods = {
+       .freeze = bt_field_type_generic_freeze,
        .validate = NULL,
        .set_byte_order = NULL,
-       .copy = (bt_field_type_common_method_copy)
+       .copy = (bt_field_type_method_copy)
                bt_field_type_string_copy,
-       .compare = bt_field_type_common_string_compare,
+       .compare = bt_field_type_string_compare,
 };
 
-static struct bt_field_type_common_methods bt_field_type_array_methods = {
-       .freeze = bt_field_type_common_array_freeze_recursive,
-       .validate = bt_field_type_common_array_validate_recursive,
-       .set_byte_order = bt_field_type_common_array_set_byte_order_recursive,
-       .copy = (bt_field_type_common_method_copy)
+static struct bt_field_type_methods bt_field_type_array_methods = {
+       .freeze = bt_field_type_array_freeze_recursive,
+       .validate = bt_field_type_array_validate_recursive,
+       .set_byte_order = bt_field_type_array_set_byte_order_recursive,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_array_copy_recursive,
-       .compare = bt_field_type_common_array_compare_recursive,
+       .compare = bt_field_type_array_compare_recursive,
 };
 
-static struct bt_field_type_common_methods bt_field_type_sequence_methods = {
-       .freeze = bt_field_type_common_sequence_freeze_recursive,
-       .validate = bt_field_type_common_sequence_validate_recursive,
-       .set_byte_order = bt_field_type_common_sequence_set_byte_order_recursive,
-       .copy = (bt_field_type_common_method_copy)
+static struct bt_field_type_methods bt_field_type_sequence_methods = {
+       .freeze = bt_field_type_sequence_freeze_recursive,
+       .validate = bt_field_type_sequence_validate_recursive,
+       .set_byte_order = bt_field_type_sequence_set_byte_order_recursive,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_sequence_copy_recursive,
-       .compare = bt_field_type_common_sequence_compare_recursive,
+       .compare = bt_field_type_sequence_compare_recursive,
 };
 
-static struct bt_field_type_common_methods bt_field_type_structure_methods = {
-       .freeze = bt_field_type_common_structure_freeze_recursive,
-       .validate = bt_field_type_common_structure_validate_recursive,
-       .set_byte_order = bt_field_type_common_structure_set_byte_order_recursive,
-       .copy = (bt_field_type_common_method_copy)
+static struct bt_field_type_methods bt_field_type_structure_methods = {
+       .freeze = bt_field_type_structure_freeze_recursive,
+       .validate = bt_field_type_structure_validate_recursive,
+       .set_byte_order = bt_field_type_structure_set_byte_order_recursive,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_structure_copy_recursive,
-       .compare = bt_field_type_common_structure_compare_recursive,
+       .compare = bt_field_type_structure_compare_recursive,
 };
 
-static struct bt_field_type_common_methods bt_field_type_variant_methods = {
-       .freeze = bt_field_type_common_variant_freeze_recursive,
-       .validate = bt_field_type_common_variant_validate_recursive,
-       .set_byte_order = bt_field_type_common_variant_set_byte_order_recursive,
-       .copy = (bt_field_type_common_method_copy)
+static struct bt_field_type_methods bt_field_type_variant_methods = {
+       .freeze = bt_field_type_variant_freeze_recursive,
+       .validate = bt_field_type_variant_validate_recursive,
+       .set_byte_order = bt_field_type_variant_set_byte_order_recursive,
+       .copy = (bt_field_type_method_copy)
                bt_field_type_variant_copy_recursive,
-       .compare = bt_field_type_common_variant_compare_recursive,
+       .compare = bt_field_type_variant_compare_recursive,
 };
 
 static
@@ -157,10 +264,10 @@ void destroy_enumeration_mapping(struct enumeration_mapping *mapping)
        g_free(mapping);
 }
 
-BT_HIDDEN
-void bt_field_type_common_initialize(struct bt_field_type_common *ft,
+static
+void bt_field_type_initialize(struct bt_field_type *ft,
                bool init_bo, bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
        BT_ASSERT(ft && (ft->id > BT_FIELD_TYPE_ID_UNKNOWN) &&
                (ft->id < BT_FIELD_TYPE_ID_NR));
@@ -174,186 +281,186 @@ void bt_field_type_common_initialize(struct bt_field_type_common *ft,
 
                BT_LOGD("Setting initial field type's byte order: bo=%s",
                        bt_common_byte_order_string(bo));
-               ret = bt_field_type_common_set_byte_order(ft, bo);
+               ret = bt_field_type_set_byte_order(ft, bo);
                BT_ASSERT(ret == 0);
        }
 
        ft->alignment = 1;
 }
 
-BT_HIDDEN
-void bt_field_type_common_integer_initialize(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_integer_initialize(
+               struct bt_field_type *ft,
                unsigned int size, bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT(size > 0);
-       BT_LOGD("Initializing common integer field type object: size=%u",
+       BT_LOGD("Initializing integer field type object: size=%u",
                size);
        ft->id = BT_FIELD_TYPE_ID_INTEGER;
        int_ft->size = size;
        int_ft->base = BT_INTEGER_BASE_DECIMAL;
        int_ft->encoding = BT_STRING_ENCODING_NONE;
-       bt_field_type_common_initialize(ft, true, release_func, methods);
-       BT_LOGD("Initialized common integer field type object: addr=%p, size=%u",
+       bt_field_type_initialize(ft, true, release_func, methods);
+       BT_LOGD("Initialized integer field type object: addr=%p, size=%u",
                ft, size);
 }
 
-BT_HIDDEN
-void bt_field_type_common_floating_point_initialize(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_floating_point_initialize(
+               struct bt_field_type *ft,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
-       BT_LOGD_STR("Initializing common floating point number field type object.");
+       BT_LOGD_STR("Initializing floating point number field type object.");
        ft->id = BT_FIELD_TYPE_ID_FLOAT;
        flt_ft->exp_dig = sizeof(float) * CHAR_BIT - FLT_MANT_DIG;
        flt_ft->mant_dig = FLT_MANT_DIG;
-       bt_field_type_common_initialize(ft, true, release_func, methods);
-       BT_LOGD("Initialized common floating point number field type object: addr=%p, "
+       bt_field_type_initialize(ft, true, release_func, methods);
+       BT_LOGD("Initialized floating point number field type object: addr=%p, "
                "exp-size=%u, mant-size=%u", ft, flt_ft->exp_dig,
                flt_ft->mant_dig);
 }
 
-BT_HIDDEN
-void bt_field_type_common_enumeration_initialize(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *container_ft,
+static
+void bt_field_type_enumeration_initialize(
+               struct bt_field_type *ft,
+               struct bt_field_type *container_ft,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
        BT_ASSERT(container_ft);
-       BT_LOGD("Initializing common enumeration field type object: int-ft-addr=%p",
+       BT_LOGD("Initializing enumeration field type object: int-ft-addr=%p",
                container_ft);
        ft->id = BT_FIELD_TYPE_ID_ENUM;
        enum_ft->container_ft = bt_get(container_ft);
        enum_ft->entries = g_ptr_array_new_with_free_func(
                (GDestroyNotify) destroy_enumeration_mapping);
-       bt_field_type_common_initialize(ft, false, release_func, methods);
-       BT_LOGD("Initialized common enumeration field type object: addr=%p, "
+       bt_field_type_initialize(ft, false, release_func, methods);
+       BT_LOGD("Initialized enumeration field type object: addr=%p, "
                "int-ft-addr=%p, int-ft-size=%u", ft, container_ft,
-               bt_field_type_common_integer_get_size(container_ft));
+               bt_field_type_integer_get_size(container_ft));
 }
 
-BT_HIDDEN
-void bt_field_type_common_string_initialize(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_string_initialize(
+               struct bt_field_type *ft,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_string *string_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_string *string_ft = (void *) ft;
 
-       BT_LOGD_STR("Initializing common string field type object.");
+       BT_LOGD_STR("Initializing string field type object.");
        ft->id = BT_FIELD_TYPE_ID_STRING;
-       bt_field_type_common_initialize(ft, true, release_func, methods);
+       bt_field_type_initialize(ft, true, release_func, methods);
        string_ft->encoding = BT_STRING_ENCODING_UTF8;
        ft->alignment = CHAR_BIT;
-       BT_LOGD("Initialized common string field type object: addr=%p", ft);
+       BT_LOGD("Initialized string field type object: addr=%p", ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_structure_initialize(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_structure_initialize(
+               struct bt_field_type *ft,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
 
-       BT_LOGD_STR("Initializing common structure field type object.");
+       BT_LOGD_STR("Initializing structure field type object.");
        ft->id = BT_FIELD_TYPE_ID_STRUCT;
        struct_ft->fields = g_array_new(FALSE, TRUE,
-               sizeof(struct bt_field_type_common_structure_field));
+               sizeof(struct bt_field_type_structure_field));
        struct_ft->field_name_to_index = g_hash_table_new(NULL, NULL);
-       bt_field_type_common_initialize(ft, true, release_func, methods);
-       BT_LOGD("Initialized common structure field type object: addr=%p", ft);
+       bt_field_type_initialize(ft, true, release_func, methods);
+       BT_LOGD("Initialized structure field type object: addr=%p", ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_array_initialize(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *element_ft,
+static
+void bt_field_type_array_initialize(
+               struct bt_field_type *ft,
+               struct bt_field_type *element_ft,
                unsigned int length, bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
 
        BT_ASSERT(element_ft);
-       BT_LOGD("Initializing common array field type object: element-ft-addr=%p, "
+       BT_LOGD("Initializing array field type object: element-ft-addr=%p, "
                "length=%u", element_ft, length);
        ft->id = BT_FIELD_TYPE_ID_ARRAY;
        array_ft->element_ft = bt_get(element_ft);
        array_ft->length = length;
-       bt_field_type_common_initialize(ft, false, release_func, methods);
-       BT_LOGD("Initialized common array field type object: addr=%p, "
+       bt_field_type_initialize(ft, false, release_func, methods);
+       BT_LOGD("Initialized array field type object: addr=%p, "
                "element-ft-addr=%p, length=%u", ft, element_ft, length);
 }
 
-BT_HIDDEN
-void bt_field_type_common_sequence_initialize(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *element_ft,
+static
+void bt_field_type_sequence_initialize(
+               struct bt_field_type *ft,
+               struct bt_field_type *element_ft,
                const char *length_field_name,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        BT_ASSERT(element_ft);
        BT_ASSERT(length_field_name);
        BT_ASSERT(bt_identifier_is_valid(length_field_name));
-       BT_LOGD("Initializing common sequence field type object: element-ft-addr=%p, "
+       BT_LOGD("Initializing sequence field type object: element-ft-addr=%p, "
                "length-field-name=\"%s\"", element_ft, length_field_name);
        ft->id = BT_FIELD_TYPE_ID_SEQUENCE;
        seq_ft->element_ft = bt_get(element_ft);
        seq_ft->length_field_name = g_string_new(length_field_name);
-       bt_field_type_common_initialize(ft, false, release_func, methods);
-       BT_LOGD("Initialized common sequence field type object: addr=%p, "
+       bt_field_type_initialize(ft, false, release_func, methods);
+       BT_LOGD("Initialized sequence field type object: addr=%p, "
                "element-ft-addr=%p, length-field-name=\"%s\"",
                ft, element_ft, length_field_name);
 }
 
-BT_HIDDEN
-void bt_field_type_common_variant_initialize(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *tag_ft,
+static
+void bt_field_type_variant_initialize(
+               struct bt_field_type *ft,
+               struct bt_field_type *tag_ft,
                const char *tag_name,
                bt_object_release_func release_func,
-               struct bt_field_type_common_methods *methods)
+               struct bt_field_type_methods *methods)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        BT_ASSERT(!tag_name || bt_identifier_is_valid(tag_name));
-       BT_LOGD("Initializing common variant field type object: "
+       BT_LOGD("Initializing variant field type object: "
                "tag-ft-addr=%p, tag-field-name=\"%s\"",
                tag_ft, tag_name);
        ft->id = BT_FIELD_TYPE_ID_VARIANT;
        var_ft->tag_name = g_string_new(tag_name);
        var_ft->choice_name_to_index = g_hash_table_new(NULL, NULL);
        var_ft->choices = g_array_new(FALSE, TRUE,
-               sizeof(struct bt_field_type_common_variant_choice));
+               sizeof(struct bt_field_type_variant_choice));
 
        if (tag_ft) {
                var_ft->tag_ft = bt_get(tag_ft);
        }
 
-       bt_field_type_common_initialize(ft, true, release_func, methods);
+       bt_field_type_initialize(ft, true, release_func, methods);
        /* A variant's alignment is undefined */
        ft->alignment = 0;
-       BT_LOGD("Initialized common variant field type object: addr=%p, "
+       BT_LOGD("Initialized variant field type object: addr=%p, "
                "tag-ft-addr=%p, tag-field-name=\"%s\"",
                ft, tag_ft, tag_name);
 }
 
-BT_HIDDEN
-void bt_field_type_common_integer_destroy(struct bt_object *obj)
+static
+void bt_field_type_integer_destroy(struct bt_object *obj)
 {
-       struct bt_field_type_common_integer *ft = (void *) obj;
+       struct bt_field_type_integer *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -365,10 +472,10 @@ void bt_field_type_common_integer_destroy(struct bt_object *obj)
        g_free(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_floating_point_destroy(struct bt_object *obj)
+static
+void bt_field_type_floating_point_destroy(struct bt_object *obj)
 {
-       struct bt_field_type_common_floating_point *ft = (void *) obj;
+       struct bt_field_type_floating_point *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -378,10 +485,10 @@ void bt_field_type_common_floating_point_destroy(struct bt_object *obj)
        g_free(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_enumeration_destroy_recursive(struct bt_object *obj)
+static
+void bt_field_type_enumeration_destroy_recursive(struct bt_object *obj)
 {
-       struct bt_field_type_common_enumeration *ft = (void *) obj;
+       struct bt_field_type_enumeration *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -394,10 +501,10 @@ void bt_field_type_common_enumeration_destroy_recursive(struct bt_object *obj)
        g_free(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_string_destroy(struct bt_object *obj)
+static
+void bt_field_type_string_destroy(struct bt_object *obj)
 {
-       struct bt_field_type_common_string *ft = (void *) obj;
+       struct bt_field_type_string *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -408,8 +515,8 @@ void bt_field_type_common_string_destroy(struct bt_object *obj)
 }
 
 static
-void bt_field_type_common_structure_field_finalize(
-               struct bt_field_type_common_structure_field *field)
+void bt_field_type_structure_field_finalize(
+               struct bt_field_type_structure_field *field)
 {
        if (!field) {
                return;
@@ -422,10 +529,10 @@ void bt_field_type_common_structure_field_finalize(
        bt_put(field->type);
 }
 
-BT_HIDDEN
-void bt_field_type_common_structure_destroy_recursive(struct bt_object *obj)
+static
+void bt_field_type_structure_destroy_recursive(struct bt_object *obj)
 {
-       struct bt_field_type_common_structure *ft = (void *) obj;
+       struct bt_field_type_structure *ft = (void *) obj;
        uint64_t i;
 
        if (!ft) {
@@ -436,8 +543,8 @@ void bt_field_type_common_structure_destroy_recursive(struct bt_object *obj)
 
        if (ft->fields) {
                for (i = 0; i < ft->fields->len; i++) {
-                       bt_field_type_common_structure_field_finalize(
-                               BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+                       bt_field_type_structure_field_finalize(
+                               BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                                        ft, i));
                }
 
@@ -451,10 +558,10 @@ void bt_field_type_common_structure_destroy_recursive(struct bt_object *obj)
        g_free(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_array_destroy_recursive(struct bt_object *obj)
+static
+void bt_field_type_array_destroy_recursive(struct bt_object *obj)
 {
-       struct bt_field_type_common_array *ft = (void *) obj;
+       struct bt_field_type_array *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -466,10 +573,10 @@ void bt_field_type_common_array_destroy_recursive(struct bt_object *obj)
        g_free(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_sequence_destroy_recursive(struct bt_object *obj)
+static
+void bt_field_type_sequence_destroy_recursive(struct bt_object *obj)
 {
-       struct bt_field_type_common_sequence *ft = (void *) obj;
+       struct bt_field_type_sequence *ft = (void *) obj;
 
        if (!ft) {
                return;
@@ -485,8 +592,8 @@ void bt_field_type_common_sequence_destroy_recursive(struct bt_object *obj)
 }
 
 static
-void bt_field_type_common_variant_choice_finalize(
-               struct bt_field_type_common_variant_choice *choice)
+void bt_field_type_variant_choice_finalize(
+               struct bt_field_type_variant_choice *choice)
 {
        if (!choice) {
                return;
@@ -503,10 +610,10 @@ void bt_field_type_common_variant_choice_finalize(
        }
 }
 
-BT_HIDDEN
-void bt_field_type_common_variant_destroy_recursive(struct bt_object *obj)
+static
+void bt_field_type_variant_destroy_recursive(struct bt_object *obj)
 {
-       struct bt_field_type_common_variant *ft = (void *) obj;
+       struct bt_field_type_variant *ft = (void *) obj;
        uint64_t i;
 
        if (!ft) {
@@ -517,8 +624,8 @@ void bt_field_type_common_variant_destroy_recursive(struct bt_object *obj)
 
        if (ft->choices) {
                for (i = 0; i < ft->choices->len; i++) {
-                       bt_field_type_common_variant_choice_finalize(
-                               BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+                       bt_field_type_variant_choice_finalize(
+                               BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                                        ft, i));
                }
 
@@ -554,68 +661,6 @@ struct range_overlap_query {
        GQuark mapping_name;
 };
 
-static
-void check_ranges_overlap(gpointer element, gpointer query)
-{
-       struct enumeration_mapping *mapping = element;
-       struct range_overlap_query *overlap_query = query;
-
-       if (mapping->range_start._signed <= overlap_query->range_end._signed
-                       && overlap_query->range_start._signed <=
-                       mapping->range_end._signed) {
-               overlap_query->overlaps = 1;
-               overlap_query->mapping_name = mapping->string;
-       }
-
-       overlap_query->overlaps |=
-               mapping->string == overlap_query->mapping_name;
-
-       if (overlap_query->overlaps) {
-               BT_LOGV("Overlapping enumeration field type mappings: "
-                       "mapping-name=\"%s\", "
-                       "mapping-a-range-start=%" PRId64 ", "
-                       "mapping-a-range-end=%" PRId64 ", "
-                       "mapping-b-range-start=%" PRId64 ", "
-                       "mapping-b-range-end=%" PRId64,
-                       g_quark_to_string(mapping->string),
-                       mapping->range_start._signed,
-                       mapping->range_end._signed,
-                       overlap_query->range_start._signed,
-                       overlap_query->range_end._signed);
-       }
-}
-
-static
-void check_ranges_overlap_unsigned(gpointer element, gpointer query)
-{
-       struct enumeration_mapping *mapping = element;
-       struct range_overlap_query *overlap_query = query;
-
-       if (mapping->range_start._unsigned <= overlap_query->range_end._unsigned
-                       && overlap_query->range_start._unsigned <=
-                       mapping->range_end._unsigned) {
-               overlap_query->overlaps = 1;
-               overlap_query->mapping_name = mapping->string;
-       }
-
-       overlap_query->overlaps |=
-               mapping->string == overlap_query->mapping_name;
-
-       if (overlap_query->overlaps) {
-               BT_LOGW("Overlapping enumeration field type mappings: "
-                       "mapping-name=\"%s\", "
-                       "mapping-a-range-start=%" PRIu64 ", "
-                       "mapping-a-range-end=%" PRIu64 ", "
-                       "mapping-b-range-start=%" PRIu64 ", "
-                       "mapping-b-range-end=%" PRIu64,
-                       g_quark_to_string(mapping->string),
-                       mapping->range_start._unsigned,
-                       mapping->range_end._unsigned,
-                       overlap_query->range_start._unsigned,
-                       overlap_query->range_end._unsigned);
-       }
-}
-
 static
 gint compare_enumeration_mappings_signed(struct enumeration_mapping **a,
                struct enumeration_mapping **b)
@@ -633,12 +678,12 @@ gint compare_enumeration_mappings_unsigned(struct enumeration_mapping **a,
 static
 int add_structure_variant_member(GArray *members,
                GHashTable *field_name_to_index,
-               struct bt_field_type_common *field_type, const char *field_name,
+               struct bt_field_type *field_type, const char *field_name,
                bool is_variant)
 {
        int ret = 0;
        GQuark name_quark = g_quark_from_string(field_name);
-       struct bt_field_type_common **member_ft;
+       struct bt_field_type **member_ft;
        GQuark *member_name;
 
        /* Make sure structure does not contain a field of the same name */
@@ -653,21 +698,21 @@ int add_structure_variant_member(GArray *members,
        g_array_set_size(members, members->len + 1);
 
        if (is_variant) {
-               struct bt_field_type_common_variant_choice *choice =
+               struct bt_field_type_variant_choice *choice =
                        &g_array_index(members,
-                               struct bt_field_type_common_variant_choice,
+                               struct bt_field_type_variant_choice,
                                members->len - 1);
 
                member_ft = &choice->type;
                member_name = &choice->name;
                BT_ASSERT(!choice->ranges);
                choice->ranges = g_array_new(FALSE, TRUE,
-                       sizeof(struct bt_field_type_common_variant_choice_range));
+                       sizeof(struct bt_field_type_variant_choice_range));
                BT_ASSERT(choice->ranges);
        } else {
-               struct bt_field_type_common_structure_field *field =
+               struct bt_field_type_structure_field *field =
                        &g_array_index(members,
-                               struct bt_field_type_common_structure_field,
+                               struct bt_field_type_structure_field,
                                members->len - 1);
 
                member_ft = &field->type;
@@ -686,11 +731,11 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_integer_validate(struct bt_field_type_common *ft)
+static
+int bt_field_type_integer_validate(struct bt_field_type *ft)
 {
        int ret = 0;
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        if (int_ft->mapped_clock_class && int_ft->is_signed) {
                BT_LOGW("Invalid integer field type: cannot be signed and have a mapped clock class: "
@@ -706,10 +751,10 @@ end:
 }
 
 static
-struct enumeration_mapping *bt_field_type_common_enumeration_get_mapping_by_index(
-               struct bt_field_type_common *ft, uint64_t index)
+struct enumeration_mapping *bt_field_type_enumeration_get_mapping_by_index(
+               struct bt_field_type *ft, uint64_t index)
 {
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
        struct enumeration_mapping *mapping = NULL;
 
        if (index >= enum_ft->entries->len) {
@@ -730,8 +775,8 @@ end:
  * Only used when freezing an enumeration.
  */
 static
-void bt_field_type_common_enumeration_set_range_overlap(
-               struct bt_field_type_common_enumeration *ft)
+void bt_field_type_enumeration_set_range_overlap(
+               struct bt_field_type_enumeration *ft)
 {
        int64_t i, j, len;
        int is_signed;
@@ -739,17 +784,16 @@ void bt_field_type_common_enumeration_set_range_overlap(
        BT_LOGV("Setting enumeration field type's overlap flag: addr=%p",
                ft);
        len = ft->entries->len;
-       is_signed = bt_field_type_common_integer_is_signed(
-               BT_TO_COMMON(ft->container_ft));
+       is_signed = bt_field_type_integer_is_signed((void *) ft->container_ft);
 
        for (i = 0; i < len; i++) {
                for (j = i + 1; j < len; j++) {
                        struct enumeration_mapping *mapping[2];
 
-                       mapping[0] = bt_field_type_common_enumeration_get_mapping_by_index(
-                               BT_TO_COMMON(ft), i);
-                       mapping[1] = bt_field_type_common_enumeration_get_mapping_by_index(
-                               BT_TO_COMMON(ft), j);
+                       mapping[0] = bt_field_type_enumeration_get_mapping_by_index(
+                               (void *) ft, i);
+                       mapping[1] = bt_field_type_enumeration_get_mapping_by_index(
+                               (void *) ft, j);
                        if (is_signed) {
                                if (mapping[0]->range_start._signed
                                                        <= mapping[1]->range_end._signed
@@ -778,15 +822,14 @@ end:
        }
 }
 
-BT_HIDDEN
-int bt_field_type_common_enumeration_validate_recursive(
-               struct bt_field_type_common *ft)
+static
+int bt_field_type_enumeration_validate_recursive(
+               struct bt_field_type *ft)
 {
        int ret = 0;
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
-       ret = bt_field_type_common_integer_validate(
-                       BT_TO_COMMON(enum_ft->container_ft));
+       ret = bt_field_type_integer_validate((void *) enum_ft->container_ft);
        if (ret) {
                BT_LOGW("Invalid enumeration field type: container type is invalid: "
                        "enum-ft-addr=%p, int-ft-addr=%p",
@@ -806,12 +849,12 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_sequence_validate_recursive(
-               struct bt_field_type_common *ft)
+static
+int bt_field_type_sequence_validate_recursive(
+               struct bt_field_type *ft)
 {
        int ret = 0;
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        /* Length field name should be set at this point */
        if (seq_ft->length_field_name->len == 0) {
@@ -821,7 +864,7 @@ int bt_field_type_common_sequence_validate_recursive(
                goto end;
        }
 
-       ret = bt_field_type_common_validate(seq_ft->element_ft);
+       ret = bt_field_type_validate(seq_ft->element_ft);
        if (ret) {
                BT_LOGW("Invalid sequence field type: invalid element field type: "
                        "seq-ft-addr=%p, element-ft-add=%p",
@@ -832,14 +875,14 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_array_validate_recursive(
-               struct bt_field_type_common *ft)
+static
+int bt_field_type_array_validate_recursive(
+               struct bt_field_type *ft)
 {
        int ret = 0;
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
 
-       ret = bt_field_type_common_validate(array_ft->element_ft);
+       ret = bt_field_type_validate(array_ft->element_ft);
        if (ret) {
                BT_LOGW("Invalid array field type: invalid element field type: "
                        "array-ft-addr=%p, element-ft-add=%p",
@@ -849,14 +892,14 @@ int bt_field_type_common_array_validate_recursive(
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_structure_validate_recursive(
-               struct bt_field_type_common *ft)
+static
+int bt_field_type_structure_validate_recursive(
+               struct bt_field_type *ft)
 {
        int ret = 0;
-       struct bt_field_type_common *child_ft = NULL;
+       struct bt_field_type *child_ft = NULL;
        int64_t field_count =
-               bt_field_type_common_structure_get_field_count(ft);
+               bt_field_type_structure_get_field_count(ft);
        int64_t i;
 
        BT_ASSERT(field_count >= 0);
@@ -864,10 +907,10 @@ int bt_field_type_common_structure_validate_recursive(
        for (i = 0; i < field_count; ++i) {
                const char *field_name;
 
-               ret = bt_field_type_common_structure_borrow_field_by_index(ft,
+               ret = bt_field_type_structure_borrow_field_by_index(ft,
                        &field_name, &child_ft, i);
                BT_ASSERT(ret == 0);
-               ret = bt_field_type_common_validate(child_ft);
+               ret = bt_field_type_validate(child_ft);
                if (ret) {
                        BT_LOGW("Invalid structure field type: "
                                "a contained field type is invalid: "
@@ -883,24 +926,24 @@ end:
 }
 
 static
-bt_bool bt_field_type_common_enumeration_has_overlapping_ranges(
-               struct bt_field_type_common_enumeration *enum_ft)
+bt_bool bt_field_type_enumeration_has_overlapping_ranges(
+               struct bt_field_type_enumeration *enum_ft)
 {
        if (!enum_ft->common.frozen) {
-               bt_field_type_common_enumeration_set_range_overlap(enum_ft);
+               bt_field_type_enumeration_set_range_overlap(enum_ft);
        }
 
        return enum_ft->has_overlapping_ranges;
 }
 
-BT_HIDDEN
-int bt_field_type_common_variant_validate_recursive(
-               struct bt_field_type_common *ft)
+static
+int bt_field_type_variant_validate_recursive(
+               struct bt_field_type *ft)
 {
        int ret = 0;
        int64_t field_count;
-       struct bt_field_type_common *child_ft = NULL;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type *child_ft = NULL;
+       struct bt_field_type_variant *var_ft = (void *) ft;
        int64_t i;
 
        if (var_ft->tag_name->len == 0) {
@@ -918,7 +961,7 @@ int bt_field_type_common_variant_validate_recursive(
                goto end;
        }
 
-       if (bt_field_type_common_enumeration_has_overlapping_ranges(var_ft->tag_ft)) {
+       if (bt_field_type_enumeration_has_overlapping_ranges(var_ft->tag_ft)) {
                BT_LOGW("Invalid variant field type: enumeration tag field type has overlapping ranges: "
                        "variant-ft-addr=%p, tag-field-name=\"%s\", "
                        "enum-ft-addr=%p", ft, var_ft->tag_name->str,
@@ -941,7 +984,7 @@ int bt_field_type_common_variant_validate_recursive(
         * enumeration while reading a variant field, an error will be
         * generated at that point (while reading the stream).
         */
-       field_count = bt_field_type_common_variant_get_field_count(ft);
+       field_count = bt_field_type_variant_get_field_count(ft);
        if (field_count < 0) {
                BT_LOGW("Invalid variant field type: no fields: "
                        "addr=%p, tag-field-name=\"%s\"",
@@ -953,10 +996,10 @@ int bt_field_type_common_variant_validate_recursive(
        for (i = 0; i < field_count; ++i) {
                const char *field_name;
 
-               ret = bt_field_type_common_variant_borrow_field_by_index(ft,
+               ret = bt_field_type_variant_borrow_field_by_index(ft,
                        &field_name, &child_ft, i);
                BT_ASSERT(ret == 0);
-               ret = bt_field_type_common_validate(child_ft);
+               ret = bt_field_type_validate(child_ft);
                if (ret) {
                        BT_LOGW("Invalid variant field type: "
                                "a contained field type is invalid: "
@@ -980,7 +1023,7 @@ end:
  * applicable.
  */
 BT_HIDDEN
-int bt_field_type_common_validate(struct bt_field_type_common *ft)
+int bt_field_type_validate(struct bt_field_type *ft)
 {
        int ret = 0;
 
@@ -1007,7 +1050,7 @@ end:
 
 struct bt_field_type *bt_field_type_integer_create(unsigned int size)
 {
-       struct bt_field_type_common_integer *integer = NULL;
+       struct bt_field_type_integer *integer = NULL;
 
        BT_LOGD("Creating integer field type object: size=%u", size);
 
@@ -1017,14 +1060,14 @@ struct bt_field_type *bt_field_type_integer_create(unsigned int size)
                goto error;
        }
 
-       integer = g_new0(struct bt_field_type_common_integer, 1);
+       integer = g_new0(struct bt_field_type_integer, 1);
        if (!integer) {
                BT_LOGE_STR("Failed to allocate one integer field type.");
                goto error;
        }
 
-       bt_field_type_common_integer_initialize(BT_TO_COMMON(integer),
-               size, bt_field_type_common_integer_destroy,
+       bt_field_type_integer_initialize((void *) integer,
+               size, bt_field_type_integer_destroy,
                &bt_field_type_integer_methods);
        BT_LOGD("Created integer field type object: addr=%p, size=%u",
                integer, size);
@@ -1037,44 +1080,32 @@ end:
        return (void *) integer;
 }
 
-BT_HIDDEN
-int bt_field_type_common_integer_get_size(struct bt_field_type_common *ft)
+
+int bt_field_type_integer_get_size(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
                "Field type");
        return (int) int_ft->size;
 }
 
-int bt_field_type_integer_get_size(struct bt_field_type *ft)
-{
-       return bt_field_type_common_integer_get_size((void *) ft);
-}
-
-BT_HIDDEN
-bt_bool bt_field_type_common_integer_is_signed(struct bt_field_type_common *ft)
+bt_bool bt_field_type_integer_is_signed(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
                "Field type");
        return int_ft->is_signed;
 }
 
-bt_bool bt_field_type_integer_is_signed(struct bt_field_type *ft)
-{
-       return bt_field_type_common_integer_is_signed((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_integer_set_is_signed(struct bt_field_type_common *ft,
+int bt_field_type_integer_set_is_signed(struct bt_field_type *ft,
                bt_bool is_signed)
 {
        int ret = 0;
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -1105,19 +1136,11 @@ end:
        return ret;
 }
 
-int bt_field_type_integer_set_is_signed(struct bt_field_type *ft,
-               bt_bool is_signed)
-{
-       return bt_field_type_common_integer_set_is_signed((void *) ft,
-               is_signed);
-}
-
-BT_HIDDEN
-int bt_field_type_common_integer_set_size(struct bt_field_type_common *ft,
+int bt_field_type_integer_set_size(struct bt_field_type *ft,
                unsigned int size)
 {
        int ret = 0;
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -1155,36 +1178,22 @@ end:
        return ret;
 }
 
-int bt_field_type_integer_set_size(struct bt_field_type *ft,
-               unsigned int size)
-{
-       return bt_field_type_common_integer_set_size((void *) ft, size);
-}
-
-BT_HIDDEN
-enum bt_integer_base bt_field_type_common_integer_get_base(
-               struct bt_field_type_common *ft)
+enum bt_integer_base bt_field_type_integer_get_base(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
                "Field type");
        return int_ft->base;
 }
 
-enum bt_integer_base bt_field_type_integer_get_base(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_integer_get_base((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_integer_set_base(struct bt_field_type_common *ft,
+int bt_field_type_integer_set_base(struct bt_field_type *ft,
                enum bt_integer_base base)
 {
        int ret = 0;
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -1230,36 +1239,22 @@ end:
        return ret;
 }
 
-int bt_field_type_integer_set_base(struct bt_field_type *ft,
-               enum bt_integer_base base)
-{
-       return bt_field_type_common_integer_set_base((void *) ft, base);
-}
-
-BT_HIDDEN
-enum bt_string_encoding bt_field_type_common_integer_get_encoding(
-               struct bt_field_type_common *ft)
+enum bt_string_encoding bt_field_type_integer_get_encoding(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
                "Field type");
        return int_ft->encoding;
 }
 
-enum bt_string_encoding bt_field_type_integer_get_encoding(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_integer_get_encoding((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_integer_set_encoding(struct bt_field_type_common *ft,
+int bt_field_type_integer_set_encoding(struct bt_field_type *ft,
                enum bt_string_encoding encoding)
 {
        int ret = 0;
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -1299,37 +1294,23 @@ end:
        return ret;
 }
 
-int bt_field_type_integer_set_encoding(struct bt_field_type *ft,
-               enum bt_string_encoding encoding)
-{
-       return bt_field_type_common_integer_set_encoding((void *) ft, encoding);
-}
-
-BT_HIDDEN
-struct bt_clock_class *bt_field_type_common_integer_borrow_mapped_clock_class(
-               struct bt_field_type_common *ft)
+struct bt_clock_class *bt_field_type_integer_borrow_mapped_clock_class(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_INTEGER,
                "Field type");
        return int_ft->mapped_clock_class;
 }
 
-struct bt_clock_class *bt_field_type_integer_borrow_mapped_clock_class(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_integer_borrow_mapped_clock_class(
-               (void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_integer_set_mapped_clock_class_no_check_frozen(
-               struct bt_field_type_common *ft,
+static
+int bt_field_type_integer_set_mapped_clock_class_no_check_frozen(
+               struct bt_field_type *ft,
                struct bt_clock_class *clock_class)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
        int ret = 0;
 
        if (!clock_class) {
@@ -1364,9 +1345,7 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_integer_set_mapped_clock_class(
-               struct bt_field_type_common *ft,
+int bt_field_type_integer_set_mapped_clock_class(struct bt_field_type *ft,
                struct bt_clock_class *clock_class)
 {
        int ret = 0;
@@ -1384,20 +1363,13 @@ int bt_field_type_common_integer_set_mapped_clock_class(
                goto end;
        }
 
-       ret = bt_field_type_common_integer_set_mapped_clock_class_no_check_frozen(
+       ret = bt_field_type_integer_set_mapped_clock_class_no_check_frozen(
                ft, clock_class);
 
 end:
        return ret;
 }
 
-int bt_field_type_integer_set_mapped_clock_class(struct bt_field_type *ft,
-               struct bt_clock_class *clock_class)
-{
-       return bt_field_type_common_integer_set_mapped_clock_class((void *) ft,
-               clock_class);
-}
-
 static
 void bt_field_type_enum_iter_destroy(struct bt_object *obj)
 {
@@ -1415,14 +1387,14 @@ void bt_field_type_enum_iter_destroy(struct bt_object *obj)
 
 static
 struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_common_enumeration_find_mappings_type(
-               struct bt_field_type_common *ft,
+bt_field_type_enumeration_find_mappings_type(
+               struct bt_field_type *ft,
                enum bt_field_type_enumeration_mapping_iterator_type iterator_type)
 {
        struct bt_field_type_enumeration_mapping_iterator *iter = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM,
                "Field type");
        iter = g_new0(struct bt_field_type_enumeration_mapping_iterator, 1);
        if (!iter) {
@@ -1439,14 +1411,13 @@ end:
        return iter;
 }
 
-BT_HIDDEN
 struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_common_enumeration_find_mappings_by_name(
-               struct bt_field_type_common *ft, const char *name)
+bt_field_type_enumeration_find_mappings_by_name(
+               struct bt_field_type *ft, const char *name)
 {
        struct bt_field_type_enumeration_mapping_iterator *iter;
 
-       iter = bt_field_type_common_enumeration_find_mappings_type(
+       iter = bt_field_type_enumeration_find_mappings_type(
                        ft, ITERATOR_BY_NAME);
        if (!iter) {
                BT_LOGW("Cannot create enumeration field type mapping iterator: "
@@ -1470,26 +1441,18 @@ error:
        return NULL;
 }
 
-struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_enumeration_find_mappings_by_name(
-               struct bt_field_type *ft, const char *name)
-{
-       return bt_field_type_common_enumeration_find_mappings_by_name(
-               (void *) ft, name);
-}
-
 int bt_field_type_enumeration_mapping_iterator_next(
                struct bt_field_type_enumeration_mapping_iterator *iter)
 {
-       struct bt_field_type_common_enumeration *enum_ft = iter->enumeration_ft;
+       struct bt_field_type_enumeration *enum_ft = iter->enumeration_ft;
        int i, ret = 0, len;
 
        BT_ASSERT_PRE_NON_NULL(iter, "Enumeration field type mapping iterator");
        len = enum_ft->entries->len;
        for (i = iter->index + 1; i < len; i++) {
                struct enumeration_mapping *mapping =
-                       bt_field_type_common_enumeration_get_mapping_by_index(
-                               BT_TO_COMMON(enum_ft), i);
+                       bt_field_type_enumeration_get_mapping_by_index(
+                               (void *) enum_ft, i);
 
                switch (iter->type) {
                case ITERATOR_BY_NAME:
@@ -1533,14 +1496,13 @@ end:
        return ret;
 }
 
-BT_HIDDEN
 struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_common_enumeration_signed_find_mappings_by_value(
-               struct bt_field_type_common *ft, int64_t value)
+bt_field_type_enumeration_signed_find_mappings_by_value(
+               struct bt_field_type *ft, int64_t value)
 {
        struct bt_field_type_enumeration_mapping_iterator *iter;
 
-       iter = bt_field_type_common_enumeration_find_mappings_type(
+       iter = bt_field_type_enumeration_find_mappings_type(
                        ft, ITERATOR_BY_SIGNED_VALUE);
        if (!iter) {
                BT_LOGW("Cannot create enumeration field type mapping iterator: "
@@ -1548,8 +1510,8 @@ bt_field_type_common_enumeration_signed_find_mappings_by_value(
                goto error;
        }
 
-       if (bt_field_type_common_integer_is_signed(
-                       BT_TO_COMMON(iter->enumeration_ft->container_ft)) != 1) {
+       if (bt_field_type_integer_is_signed(
+                       (void *) iter->enumeration_ft->container_ft) != 1) {
                BT_LOGW("Invalid parameter: enumeration field type is unsigned: "
                        "enum-ft-addr=%p, int-ft-addr=%p",
                        ft, iter->enumeration_ft->container_ft);
@@ -1565,21 +1527,12 @@ error:
 }
 
 struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_enumeration_signed_find_mappings_by_value(
-               struct bt_field_type *ft, int64_t value)
-{
-       return bt_field_type_common_enumeration_signed_find_mappings_by_value(
-               (void *) ft, value);
-}
-
-BT_HIDDEN
-struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_common_enumeration_unsigned_find_mappings_by_value(
-               struct bt_field_type_common *ft, uint64_t value)
+bt_field_type_enumeration_unsigned_find_mappings_by_value(
+               struct bt_field_type *ft, uint64_t value)
 {
        struct bt_field_type_enumeration_mapping_iterator *iter;
 
-       iter = bt_field_type_common_enumeration_find_mappings_type(
+       iter = bt_field_type_enumeration_find_mappings_type(
                        ft, ITERATOR_BY_UNSIGNED_VALUE);
        if (!iter) {
                BT_LOGW("Cannot create enumeration field type mapping iterator: "
@@ -1587,8 +1540,8 @@ bt_field_type_common_enumeration_unsigned_find_mappings_by_value(
                goto error;
        }
 
-       if (bt_field_type_common_integer_is_signed(
-                       BT_TO_COMMON(iter->enumeration_ft->container_ft)) != 0) {
+       if (bt_field_type_integer_is_signed(
+                       (void *) iter->enumeration_ft->container_ft) != 0) {
                BT_LOGW("Invalid parameter: enumeration field type is signed: "
                        "enum-ft-addr=%p, int-ft-addr=%p",
                        ft, iter->enumeration_ft->container_ft);
@@ -1603,14 +1556,6 @@ error:
        return NULL;
 }
 
-struct bt_field_type_enumeration_mapping_iterator *
-bt_field_type_enumeration_unsigned_find_mappings_by_value(
-               struct bt_field_type *ft, uint64_t value)
-{
-       return bt_field_type_common_enumeration_unsigned_find_mappings_by_value(
-               (void *) ft, value);
-}
-
 int bt_field_type_enumeration_mapping_iterator_signed_get(
                struct bt_field_type_enumeration_mapping_iterator *iter,
                const char **mapping_name, int64_t *range_begin,
@@ -1620,7 +1565,7 @@ int bt_field_type_enumeration_mapping_iterator_signed_get(
        BT_ASSERT_PRE(iter->index != -1,
                "Invalid enumeration field type mapping iterator access: "
                "addr=%p, position=-1", iter);
-       return bt_field_type_common_enumeration_signed_get_mapping_by_index(
+       return bt_field_type_enumeration_signed_get_mapping_by_index(
                        (void *) iter->enumeration_ft, iter->index,
                        mapping_name, range_begin, range_end);
 }
@@ -1634,14 +1579,13 @@ int bt_field_type_enumeration_mapping_iterator_unsigned_get(
        BT_ASSERT_PRE(iter->index != -1,
                "Invalid enumeration field type mapping iterator access: "
                "addr=%p, position=-1", iter);
-       return bt_field_type_common_enumeration_unsigned_get_mapping_by_index(
+       return bt_field_type_enumeration_unsigned_get_mapping_by_index(
                        (void *) iter->enumeration_ft, iter->index,
                        mapping_name, range_begin, range_end);
 }
 
-BT_HIDDEN
-int bt_field_type_common_enumeration_signed_get_mapping_by_index(
-               struct bt_field_type_common *ft, uint64_t index,
+int bt_field_type_enumeration_signed_get_mapping_by_index(
+               struct bt_field_type *ft, uint64_t index,
                const char **mapping_name, int64_t *range_begin,
                int64_t *range_end)
 {
@@ -1649,12 +1593,12 @@ int bt_field_type_common_enumeration_signed_get_mapping_by_index(
        struct enumeration_mapping *mapping;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft,
+       BT_ASSERT_PRE_FT_HAS_ID(ft,
                BT_FIELD_TYPE_ID_ENUM, "Field type");
-       mapping = bt_field_type_common_enumeration_get_mapping_by_index(ft,
+       mapping = bt_field_type_enumeration_get_mapping_by_index(ft,
                index);
        if (!mapping) {
-               /* bt_field_type_common_enumeration_get_mapping_by_index() logs errors */
+               /* bt_field_type_enumeration_get_mapping_by_index() logs errors */
                ret = -1;
                goto end;
        }
@@ -1676,18 +1620,8 @@ end:
        return ret;
 }
 
-int bt_field_type_enumeration_signed_get_mapping_by_index(
+int bt_field_type_enumeration_unsigned_get_mapping_by_index(
                struct bt_field_type *ft, uint64_t index,
-               const char **mapping_name, int64_t *range_begin,
-               int64_t *range_end)
-{
-       return bt_field_type_common_enumeration_signed_get_mapping_by_index(
-               (void *) ft, index, mapping_name, range_begin, range_end);
-}
-
-BT_HIDDEN
-int bt_field_type_common_enumeration_unsigned_get_mapping_by_index(
-               struct bt_field_type_common *ft, uint64_t index,
                const char **mapping_name, uint64_t *range_begin,
                uint64_t *range_end)
 {
@@ -1695,11 +1629,11 @@ int bt_field_type_common_enumeration_unsigned_get_mapping_by_index(
        struct enumeration_mapping *mapping;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
-       mapping = bt_field_type_common_enumeration_get_mapping_by_index(
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
+       mapping = bt_field_type_enumeration_get_mapping_by_index(
                ft, index);
        if (!mapping) {
-               /* bt_field_type_common_enumeration_get_mapping_by_index() reports any error */
+               /* bt_field_type_enumeration_get_mapping_by_index() reports any error */
                ret = -1;
                goto end;
        }
@@ -1721,20 +1655,11 @@ end:
        return ret;
 }
 
-int bt_field_type_enumeration_unsigned_get_mapping_by_index(
-               struct bt_field_type *ft, uint64_t index,
-               const char **mapping_name, uint64_t *range_begin,
-               uint64_t *range_end)
-{
-       return bt_field_type_common_enumeration_unsigned_get_mapping_by_index(
-               (void *) ft, index, mapping_name, range_begin, range_end);
-}
-
 struct bt_field_type *bt_field_type_enumeration_create(
                struct bt_field_type *container_ft)
 {
-       struct bt_field_type_common_enumeration *enumeration = NULL;
-       struct bt_field_type_common *int_ft = (void *) container_ft;
+       struct bt_field_type_enumeration *enumeration = NULL;
+       struct bt_field_type *int_ft = (void *) container_ft;
 
        BT_LOGD("Creating enumeration field type object: int-ft-addr=%p",
                container_ft);
@@ -1751,14 +1676,14 @@ struct bt_field_type *bt_field_type_enumeration_create(
                goto error;
        }
 
-       enumeration = g_new0(struct bt_field_type_common_enumeration, 1);
+       enumeration = g_new0(struct bt_field_type_enumeration, 1);
        if (!enumeration) {
                BT_LOGE_STR("Failed to allocate one enumeration field type.");
                goto error;
        }
 
-       bt_field_type_common_enumeration_initialize(BT_TO_COMMON(enumeration),
-               int_ft, bt_field_type_common_enumeration_destroy_recursive,
+       bt_field_type_enumeration_initialize((void *) enumeration,
+               int_ft, bt_field_type_enumeration_destroy_recursive,
                &bt_field_type_enumeration_methods);
        BT_LOGD("Created enumeration field type object: addr=%p, "
                "int-ft-addr=%p, int-ft-size=%u",
@@ -1773,34 +1698,24 @@ end:
        return (void *) enumeration;
 }
 
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_enumeration_borrow_container_field_type(
-               struct bt_field_type_common *ft)
-{
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
-
-       BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
-       return BT_TO_COMMON(enum_ft->container_ft);
-}
-
 struct bt_field_type *bt_field_type_enumeration_borrow_container_field_type(
                struct bt_field_type *ft)
 {
-       return (void *) bt_field_type_common_enumeration_borrow_container_field_type(
-               (void *) ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
+
+       BT_ASSERT_PRE_NON_NULL(ft, "Field type");
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
+       return (void *) enum_ft->container_ft;
 }
 
-BT_HIDDEN
-int bt_field_type_common_enumeration_signed_add_mapping(
-               struct bt_field_type_common *ft, const char *string,
+int bt_field_type_enumeration_signed_add_mapping(
+               struct bt_field_type *ft, const char *string,
                int64_t range_start, int64_t range_end)
 {
        int ret = 0;
        GQuark mapping_name;
        struct enumeration_mapping *mapping;
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
        char *escaped_string;
 
        if (!ft) {
@@ -1882,23 +1797,14 @@ end:
        return ret;
 }
 
-int bt_field_type_enumeration_signed_add_mapping(
+int bt_field_type_enumeration_unsigned_add_mapping(
                struct bt_field_type *ft, const char *string,
-               int64_t range_start, int64_t range_end)
-{
-       return bt_field_type_common_enumeration_signed_add_mapping(
-               (void *) ft, string, range_start, range_end);
-}
-
-BT_HIDDEN
-int bt_field_type_common_enumeration_unsigned_add_mapping(
-               struct bt_field_type_common *ft, const char *string,
                uint64_t range_start, uint64_t range_end)
 {
        int ret = 0;
        GQuark mapping_name;
        struct enumeration_mapping *mapping;
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
        char *escaped_string;
 
        if (!ft) {
@@ -1980,35 +1886,20 @@ end:
        return ret;
 }
 
-int bt_field_type_enumeration_unsigned_add_mapping(
-               struct bt_field_type *ft, const char *string,
-               uint64_t range_start, uint64_t range_end)
-{
-       return bt_field_type_common_enumeration_unsigned_add_mapping(
-               (void *) ft, string, range_start, range_end);
-}
-
-BT_HIDDEN
-int64_t bt_field_type_common_enumeration_get_mapping_count(
-               struct bt_field_type_common *ft)
+int64_t bt_field_type_enumeration_get_mapping_count(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ENUM, "Field type");
        return (int64_t) enum_ft->entries->len;
 }
 
-int64_t bt_field_type_enumeration_get_mapping_count(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_enumeration_get_mapping_count((void *) ft);
-}
-
 struct bt_field_type *bt_field_type_floating_point_create(void)
 {
-       struct bt_field_type_common_floating_point *floating_point =
-               g_new0(struct bt_field_type_common_floating_point, 1);
+       struct bt_field_type_floating_point *floating_point =
+               g_new0(struct bt_field_type_floating_point, 1);
 
        BT_LOGD_STR("Creating floating point number field type object.");
 
@@ -2017,9 +1908,9 @@ struct bt_field_type *bt_field_type_floating_point_create(void)
                goto end;
        }
 
-       bt_field_type_common_floating_point_initialize(
-               BT_TO_COMMON(floating_point),
-               bt_field_type_common_floating_point_destroy,
+       bt_field_type_floating_point_initialize(
+               (void *) floating_point,
+               bt_field_type_floating_point_destroy,
                &bt_field_type_floating_point_methods);
        BT_LOGD("Created floating point number field type object: addr=%p, "
                "exp-size=%u, mant-size=%u", floating_point,
@@ -2029,32 +1920,22 @@ end:
        return (void *) floating_point;
 }
 
-BT_HIDDEN
-int bt_field_type_common_floating_point_get_exponent_digits(
-               struct bt_field_type_common *ft)
+int bt_field_type_floating_point_get_exponent_digits(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_FLOAT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_FLOAT,
                "Field type");
        return (int) flt_ft->exp_dig;
 }
 
-int bt_field_type_floating_point_get_exponent_digits(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_floating_point_get_exponent_digits(
-               (void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_floating_point_set_exponent_digits(
-               struct bt_field_type_common *ft,
-               unsigned int exponent_digits)
+int bt_field_type_floating_point_set_exponent_digits(
+               struct bt_field_type *ft, unsigned int exponent_digits)
 {
        int ret = 0;
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -2095,38 +1976,22 @@ end:
        return ret;
 }
 
-int bt_field_type_floating_point_set_exponent_digits(
-               struct bt_field_type *ft, unsigned int exponent_digits)
-{
-       return bt_field_type_common_floating_point_set_exponent_digits(
-               (void *) ft, exponent_digits);
-}
-
-BT_HIDDEN
-int bt_field_type_common_floating_point_get_mantissa_digits(
-               struct bt_field_type_common *ft)
+int bt_field_type_floating_point_get_mantissa_digits(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_FLOAT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_FLOAT,
                "Field type");
        return (int) flt_ft->mant_dig;
 }
 
-int bt_field_type_floating_point_get_mantissa_digits(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_floating_point_get_mantissa_digits(
-               (void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_floating_point_set_mantissa_digits(
-               struct bt_field_type_common *ft, unsigned int mantissa_digits)
+int bt_field_type_floating_point_set_mantissa_digits(
+               struct bt_field_type *ft, unsigned int mantissa_digits)
 {
        int ret = 0;
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -2166,17 +2031,10 @@ end:
        return ret;
 }
 
-int bt_field_type_floating_point_set_mantissa_digits(
-               struct bt_field_type *ft, unsigned int mantissa_digits)
-{
-       return bt_field_type_common_floating_point_set_mantissa_digits(
-               (void *) ft, mantissa_digits);
-}
-
 struct bt_field_type *bt_field_type_structure_create(void)
 {
-       struct bt_field_type_common_structure *structure =
-               g_new0(struct bt_field_type_common_structure, 1);
+       struct bt_field_type_structure *structure =
+               g_new0(struct bt_field_type_structure, 1);
 
        BT_LOGD_STR("Creating structure field type object.");
 
@@ -2185,8 +2043,8 @@ struct bt_field_type *bt_field_type_structure_create(void)
                goto error;
        }
 
-       bt_field_type_common_structure_initialize(BT_TO_COMMON(structure),
-               bt_field_type_common_structure_destroy_recursive,
+       bt_field_type_structure_initialize((void *) structure,
+               bt_field_type_structure_destroy_recursive,
                &bt_field_type_structure_methods);
        BT_LOGD("Created structure field type object: addr=%p",
                structure);
@@ -2199,43 +2057,12 @@ end:
        return (void *) structure;
 }
 
-BT_HIDDEN
-int bt_field_type_common_structure_replace_field(
-               struct bt_field_type_common *ft,
-               const char *field_name,
-               struct bt_field_type_common *field_type)
-{
-       int ret = 0;
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
-       GQuark name_quark;
-       uint64_t i;
-
-       BT_ASSERT(ft);
-       BT_ASSERT(field_name);
-       BT_ASSERT(field_type);
-       BT_ASSERT(ft->id == BT_FIELD_TYPE_ID_STRUCT);
-       name_quark = g_quark_from_string(field_name);
-
-       for (i = 0; i < struct_ft->fields->len; i++) {
-               struct bt_field_type_common_structure_field *field =
-                       BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(ft, i);
-
-               if (field->name == name_quark) {
-                       bt_put(field->type);
-                       field->type = bt_get(field_type);
-               }
-       }
-
-       return ret;
-}
-
-BT_HIDDEN
-int bt_field_type_common_structure_add_field(struct bt_field_type_common *ft,
-               struct bt_field_type_common *field_type,
+int bt_field_type_structure_add_field(struct bt_field_type *ft,
+               struct bt_field_type *field_type,
                const char *field_name)
 {
        int ret = 0;
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
 
        /*
         * TODO: check that `field_type` does not contain `type`,
@@ -2293,48 +2120,32 @@ end:
        return ret;
 }
 
-int bt_field_type_structure_add_field(struct bt_field_type *ft,
-               struct bt_field_type *field_type,
-               const char *field_name)
-{
-       return bt_field_type_common_structure_add_field((void *) ft,
-               (void *) field_type, field_name);
-}
-
-BT_HIDDEN
-int64_t bt_field_type_common_structure_get_field_count(
-               struct bt_field_type_common *ft)
+int64_t bt_field_type_structure_get_field_count(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
                "Field type");
        return (int64_t) struct_ft->fields->len;
 }
 
-int64_t bt_field_type_structure_get_field_count(struct bt_field_type *ft)
-{
-       return bt_field_type_common_structure_get_field_count((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_structure_borrow_field_by_index(
-               struct bt_field_type_common *ft,
+int bt_field_type_structure_borrow_field_by_index(
+               struct bt_field_type *ft,
                const char **field_name,
-               struct bt_field_type_common **field_type, uint64_t index)
+               struct bt_field_type **field_type, uint64_t index)
 {
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common_structure_field *field;
+       struct bt_field_type_structure *struct_ft = (void *) ft;
+       struct bt_field_type_structure_field *field;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
                "Field type");
        BT_ASSERT_PRE(index < struct_ft->fields->len,
                "Index is out of bounds: index=%" PRIu64 ", "
-               "count=%u, %![ft-]+_F",
+               "count=%u, %![ft-]+F",
                index, struct_ft->fields->len, ft);
-       field = BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(struct_ft, index);
+       field = BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(struct_ft, index);
 
        if (field_type) {
                *field_type = field->type;
@@ -2348,29 +2159,18 @@ int bt_field_type_common_structure_borrow_field_by_index(
        return 0;
 }
 
-int bt_field_type_structure_borrow_field_by_index(
-               struct bt_field_type *ft,
-               const char **field_name,
-               struct bt_field_type **field_type, uint64_t index)
-{
-       return bt_field_type_common_structure_borrow_field_by_index(
-               (void *) ft, field_name, (void *) field_type, index);
-}
-
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_structure_borrow_field_type_by_name(
-               struct bt_field_type_common *ft, const char *name)
+struct bt_field_type *bt_field_type_structure_borrow_field_type_by_name(
+               struct bt_field_type *ft, const char *name)
 {
        size_t index;
        GQuark name_quark;
-       struct bt_field_type_common_structure_field *field;
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common *field_type = NULL;
+       struct bt_field_type_structure_field *field;
+       struct bt_field_type_structure *struct_ft = (void *) ft;
+       struct bt_field_type *field_type = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        BT_ASSERT_PRE_NON_NULL(name, "Name");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
                "Field type");
        name_quark = g_quark_try_string(name);
        if (!name_quark) {
@@ -2388,24 +2188,17 @@ bt_field_type_common_structure_borrow_field_type_by_name(
                goto end;
        }
 
-       field = BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(ft, index);
+       field = BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(ft, index);
        field_type = field->type;
 
 end:
        return field_type;
 }
 
-struct bt_field_type *bt_field_type_structure_borrow_field_type_by_name(
-               struct bt_field_type *ft, const char *name)
-{
-       return (void *) bt_field_type_common_structure_borrow_field_type_by_name(
-               (void *) ft, name);
-}
-
 struct bt_field_type *bt_field_type_variant_create(
        struct bt_field_type *tag_ft, const char *tag_name)
 {
-       struct bt_field_type_common_variant *var_ft = NULL;
+       struct bt_field_type_variant *var_ft = NULL;
 
        BT_LOGD("Creating variant field type object: "
                "tag-ft-addr=%p, tag-field-name=\"%s\"",
@@ -2418,15 +2211,15 @@ struct bt_field_type *bt_field_type_variant_create(
                goto error;
        }
 
-       var_ft = g_new0(struct bt_field_type_common_variant, 1);
+       var_ft = g_new0(struct bt_field_type_variant, 1);
        if (!var_ft) {
                BT_LOGE_STR("Failed to allocate one variant field type.");
                goto error;
        }
 
-       bt_field_type_common_variant_initialize(BT_TO_COMMON(var_ft),
+       bt_field_type_variant_initialize((void *) var_ft,
                (void *) tag_ft, tag_name,
-               bt_field_type_common_variant_destroy_recursive,
+               bt_field_type_variant_destroy_recursive,
                &bt_field_type_variant_methods);
        BT_LOGD("Created variant field type object: addr=%p, "
                "tag-ft-addr=%p, tag-field-name=\"%s\"",
@@ -2440,16 +2233,14 @@ end:
        return (void *) var_ft;
 }
 
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_variant_borrow_tag_field_type(
-               struct bt_field_type_common *ft)
+struct bt_field_type *bt_field_type_variant_borrow_tag_field_type(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common *tag_ft = NULL;
+       struct bt_field_type_variant *var_ft = (void *) ft;
+       struct bt_field_type *tag_ft = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
 
        if (!var_ft->tag_ft) {
@@ -2458,28 +2249,19 @@ bt_field_type_common_variant_borrow_tag_field_type(
                goto end;
        }
 
-       tag_ft = BT_TO_COMMON(var_ft->tag_ft);
+       tag_ft = (void *) var_ft->tag_ft;
 
 end:
        return tag_ft;
 }
 
-struct bt_field_type *bt_field_type_variant_borrow_tag_field_type(
-               struct bt_field_type *ft)
-{
-       return (void *) bt_field_type_common_variant_borrow_tag_field_type(
-               (void *) ft);
-}
-
-BT_HIDDEN
-const char *bt_field_type_common_variant_get_tag_name(
-               struct bt_field_type_common *ft)
+const char *bt_field_type_variant_get_tag_name(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
        const char *tag_name = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
 
        if (var_ft->tag_name->len == 0) {
@@ -2494,17 +2276,11 @@ end:
        return tag_name;
 }
 
-const char *bt_field_type_variant_get_tag_name(struct bt_field_type *ft)
-{
-       return bt_field_type_common_variant_get_tag_name((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_variant_set_tag_name(
-               struct bt_field_type_common *ft, const char *name)
+int bt_field_type_variant_set_tag_name(
+               struct bt_field_type *ft, const char *name)
 {
        int ret = 0;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -2542,20 +2318,13 @@ end:
        return ret;
 }
 
-int bt_field_type_variant_set_tag_name(
-               struct bt_field_type *ft, const char *name)
-{
-       return bt_field_type_common_variant_set_tag_name((void *) ft, name);
-}
-
-BT_HIDDEN
-int bt_field_type_common_variant_add_field(struct bt_field_type_common *ft,
-               struct bt_field_type_common *field_type,
+int bt_field_type_variant_add_field(struct bt_field_type *ft,
+               struct bt_field_type *field_type,
                const char *field_name)
 {
        size_t i;
        int ret = 0;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
        GQuark field_name_quark = g_quark_from_string(field_name);
 
        /*
@@ -2636,29 +2405,19 @@ end:
        return ret;
 }
 
-int bt_field_type_variant_add_field(struct bt_field_type *ft,
-               struct bt_field_type *field_type,
-               const char *field_name)
-{
-       return bt_field_type_common_variant_add_field((void *) ft,
-               (void *) field_type, field_name);
-}
-
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_variant_borrow_field_type_by_name(
-               struct bt_field_type_common *ft,
+struct bt_field_type *bt_field_type_variant_borrow_field_type_by_name(
+               struct bt_field_type *ft,
                const char *field_name)
 {
        size_t index;
        GQuark name_quark;
-       struct bt_field_type_common_variant_choice *choice;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common *field_type = NULL;
+       struct bt_field_type_variant_choice *choice;
+       struct bt_field_type_variant *var_ft = (void *) ft;
+       struct bt_field_type *field_type = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        BT_ASSERT_PRE_NON_NULL(field_name, "Name");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
        name_quark = g_quark_try_string(field_name);
        if (!name_quark) {
@@ -2676,55 +2435,38 @@ bt_field_type_common_variant_borrow_field_type_by_name(
                goto end;
        }
 
-       choice = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(ft, index);
+       choice = BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(ft, index);
        field_type = choice->type;
 
 end:
        return field_type;
 }
 
-struct bt_field_type *bt_field_type_variant_borrow_field_type_by_name(
-               struct bt_field_type *ft,
-               const char *field_name)
-{
-       return (void *) bt_field_type_common_variant_borrow_field_type_by_name(
-               (void *) ft, field_name);
-}
-
-BT_HIDDEN
-int64_t bt_field_type_common_variant_get_field_count(
-               struct bt_field_type_common *ft)
+int64_t bt_field_type_variant_get_field_count(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Variant field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
        return (int64_t) var_ft->choices->len;
 }
 
-int64_t bt_field_type_variant_get_field_count(struct bt_field_type *ft)
-{
-       return bt_field_type_common_variant_get_field_count((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_variant_borrow_field_by_index(
-               struct bt_field_type_common *ft,
-               const char **field_name,
-               struct bt_field_type_common **field_type, uint64_t index)
+int bt_field_type_variant_borrow_field_by_index(struct bt_field_type *ft,
+               const char **field_name, struct bt_field_type **field_type,
+               uint64_t index)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common_variant_choice *choice;
+       struct bt_field_type_variant *var_ft = (void *) ft;
+       struct bt_field_type_variant_choice *choice;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
        BT_ASSERT_PRE(index < var_ft->choices->len,
                "Index is out of bounds: index=%" PRIu64 ", "
-               "count=%u, %![ft-]+_F",
+               "count=%u, %![ft-]+F",
                index, var_ft->choices->len, ft);
-       choice = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(ft, index);
+       choice = BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(ft, index);
 
        if (field_type) {
                *field_type = choice->type;
@@ -2738,42 +2480,34 @@ int bt_field_type_common_variant_borrow_field_by_index(
        return 0;
 }
 
-int bt_field_type_variant_borrow_field_by_index(struct bt_field_type *ft,
-               const char **field_name, struct bt_field_type **field_type,
-               uint64_t index)
-{
-       return bt_field_type_common_variant_borrow_field_by_index((void *) ft,
-               field_name, (void *) field_type, index);
-}
-
 BT_HIDDEN
-int64_t bt_field_type_common_variant_find_choice_index(
-               struct bt_field_type_common *ft, uint64_t uval,
+int64_t bt_field_type_variant_find_choice_index(
+               struct bt_field_type *ft, uint64_t uval,
                bool is_signed)
 {
        int64_t ret;
        uint64_t i;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        BT_ASSERT(ft);
        BT_ASSERT(ft->id == BT_FIELD_TYPE_ID_VARIANT);
 
-       if (bt_field_type_common_variant_update_choices(ft)) {
+       if (bt_field_type_variant_update_choices(ft)) {
                ret = INT64_C(-1);
                goto end;
        }
 
        for (i = 0; i < var_ft->choices->len; i++) {
                uint64_t range_i;
-               struct bt_field_type_common_variant_choice *choice =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+               struct bt_field_type_variant_choice *choice =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                                var_ft, i);
 
                for (range_i = 0; range_i < choice->ranges->len; range_i++) {
-                       struct bt_field_type_common_variant_choice_range *range =
+                       struct bt_field_type_variant_choice_range *range =
                                &g_array_index(
                                        choice->ranges,
-                                       struct bt_field_type_common_variant_choice_range,
+                                       struct bt_field_type_variant_choice_range,
                                        range_i);
 
                        if (is_signed) {
@@ -2806,7 +2540,7 @@ end:
 struct bt_field_type *bt_field_type_array_create(
                struct bt_field_type *element_ft, unsigned int length)
 {
-       struct bt_field_type_common_array *array = NULL;
+       struct bt_field_type_array *array = NULL;
 
        BT_LOGD("Creating array field type object: element-ft-addr=%p, "
                "length=%u", element_ft, length);
@@ -2816,115 +2550,60 @@ struct bt_field_type *bt_field_type_array_create(
                goto error;
        }
 
-       if (length == 0) {
-               BT_LOGW_STR("Invalid parameter: length is zero.");
-               goto error;
-       }
-
-       array = g_new0(struct bt_field_type_common_array, 1);
-       if (!array) {
-               BT_LOGE_STR("Failed to allocate one array field type.");
-               goto error;
-       }
-
-       bt_field_type_common_array_initialize(BT_TO_COMMON(array),
-               (void *) element_ft, length,
-               bt_field_type_common_array_destroy_recursive,
-               &bt_field_type_array_methods);
-       BT_LOGD("Created array field type object: addr=%p, "
-               "element-ft-addr=%p, length=%u",
-               array, element_ft, length);
-       goto end;
-
-error:
-       BT_PUT(array);
-
-end:
-       return (void *) array;
-}
-
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_array_borrow_element_field_type(
-               struct bt_field_type_common *ft)
-{
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
-
-       BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ARRAY,
-               "Field type");
-       BT_ASSERT(array_ft && array_ft->element_ft);
-       return array_ft->element_ft;
-}
-
-struct bt_field_type *bt_field_type_array_borrow_element_field_type(
-               struct bt_field_type *ft)
-{
-       return (void *) bt_field_type_common_array_borrow_element_field_type(
-               (void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_array_set_element_field_type(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *element_ft)
-{
-       int ret = 0;
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
-
-       if (!ft) {
-               BT_LOGW_STR("Invalid parameter: array field type is NULL.");
-               ret = -1;
-               goto end;
-       }
-
-       if (!element_ft) {
-               BT_LOGW_STR("Invalid parameter: element field type is NULL.");
-               ret = -1;
-               goto end;
-       }
-
-       if (ft->id != BT_FIELD_TYPE_ID_ARRAY) {
-               BT_LOGW("Invalid parameter: field type is not an array field type: "
-                       "addr=%p, ft-id=%s", ft,
-                       bt_common_field_type_id_string(ft->id));
-               ret = -1;
-               goto end;
+       if (length == 0) {
+               BT_LOGW_STR("Invalid parameter: length is zero.");
+               goto error;
        }
 
-       if (array_ft->element_ft) {
-               BT_PUT(array_ft->element_ft);
+       array = g_new0(struct bt_field_type_array, 1);
+       if (!array) {
+               BT_LOGE_STR("Failed to allocate one array field type.");
+               goto error;
        }
 
-       array_ft->element_ft = bt_get(element_ft);
-       BT_LOGV("Set array field type's element field type: array-ft-addr=%p, "
-               "element-ft-addr=%p", ft, element_ft);
+       bt_field_type_array_initialize((void *) array,
+               (void *) element_ft, length,
+               bt_field_type_array_destroy_recursive,
+               &bt_field_type_array_methods);
+       BT_LOGD("Created array field type object: addr=%p, "
+               "element-ft-addr=%p, length=%u",
+               array, element_ft, length);
+       goto end;
+
+error:
+       BT_PUT(array);
 
 end:
-       return ret;
+       return (void *) array;
 }
 
-BT_HIDDEN
-int64_t bt_field_type_common_array_get_length(struct bt_field_type_common *ft)
+struct bt_field_type *bt_field_type_array_borrow_element_field_type(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_ARRAY,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ARRAY,
                "Field type");
-       return (int64_t) array_ft->length;
+       BT_ASSERT(array_ft && array_ft->element_ft);
+       return array_ft->element_ft;
 }
 
 int64_t bt_field_type_array_get_length(struct bt_field_type *ft)
 {
-       return bt_field_type_common_array_get_length((void *) ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
+
+       BT_ASSERT_PRE_NON_NULL(ft, "Field type");
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_ARRAY,
+               "Field type");
+       return (int64_t) array_ft->length;
 }
 
 struct bt_field_type *bt_field_type_sequence_create(
                struct bt_field_type *element_ft,
                const char *length_field_name)
 {
-       struct bt_field_type_common_sequence *sequence = NULL;
+       struct bt_field_type_sequence *sequence = NULL;
 
        BT_LOGD("Creating sequence field type object: element-ft-addr=%p, "
                "length-field-name=\"%s\"", element_ft, length_field_name);
@@ -2940,15 +2619,15 @@ struct bt_field_type *bt_field_type_sequence_create(
                goto error;
        }
 
-       sequence = g_new0(struct bt_field_type_common_sequence, 1);
+       sequence = g_new0(struct bt_field_type_sequence, 1);
        if (!sequence) {
                BT_LOGE_STR("Failed to allocate one sequence field type.");
                goto error;
        }
 
-       bt_field_type_common_sequence_initialize(BT_TO_COMMON(sequence),
+       bt_field_type_sequence_initialize((void *) sequence,
                (void *) element_ft, length_field_name,
-               bt_field_type_common_sequence_destroy_recursive,
+               bt_field_type_sequence_destroy_recursive,
                &bt_field_type_sequence_methods);
        BT_LOGD("Created sequence field type object: addr=%p, "
                "element-ft-addr=%p, length-field-name=\"%s\"",
@@ -2962,89 +2641,33 @@ end:
        return (void *) sequence;
 }
 
-BT_HIDDEN
-struct bt_field_type_common *bt_field_type_common_sequence_borrow_element_field_type(
-               struct bt_field_type_common *ft)
+struct bt_field_type *bt_field_type_sequence_borrow_element_field_type(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
                "Field type");
        return seq_ft->element_ft;
 }
 
-struct bt_field_type *bt_field_type_sequence_borrow_element_field_type(
+const char *bt_field_type_sequence_get_length_field_name(
                struct bt_field_type *ft)
 {
-       return (void *) bt_field_type_common_sequence_borrow_element_field_type(
-               (void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_sequence_set_element_field_type(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *element_ft)
-{
-       int ret = 0;
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
-
-       if (!ft) {
-               BT_LOGW_STR("Invalid parameter: sequence field type is NULL.");
-               ret = -1;
-               goto end;
-       }
-
-       if (!element_ft) {
-               BT_LOGW_STR("Invalid parameter: element field type is NULL.");
-               ret = -1;
-               goto end;
-       }
-
-       if (ft->id != BT_FIELD_TYPE_ID_SEQUENCE) {
-               BT_LOGW("Invalid parameter: field type is not a sequence field type: "
-                       "addr=%p, ft-id=%s", ft,
-                       bt_common_field_type_id_string(ft->id));
-               ret = -1;
-               goto end;
-       }
-
-       if (seq_ft->element_ft) {
-               BT_PUT(seq_ft->element_ft);
-       }
-
-       seq_ft->element_ft = element_ft;
-       bt_get(seq_ft->element_ft);
-       BT_LOGV("Set sequence field type's element field type: sequence-ft-addr=%p, "
-               "element-ft-addr=%p", ft, element_ft);
-
-end:
-       return ret;
-}
-
-BT_HIDDEN
-const char *bt_field_type_common_sequence_get_length_field_name(
-               struct bt_field_type_common *ft)
-{
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
                "Field type");
        return seq_ft->length_field_name ?
                seq_ft->length_field_name->str : NULL;
 }
 
-const char *bt_field_type_sequence_get_length_field_name(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_sequence_get_length_field_name((void *) ft);
-}
-
 struct bt_field_type *bt_field_type_string_create(void)
 {
-       struct bt_field_type_common_string *string =
-               g_new0(struct bt_field_type_common_string, 1);
+       struct bt_field_type_string *string =
+               g_new0(struct bt_field_type_string, 1);
 
        BT_LOGD_STR("Creating string field type object.");
 
@@ -3053,37 +2676,29 @@ struct bt_field_type *bt_field_type_string_create(void)
                return NULL;
        }
 
-       bt_field_type_common_string_initialize(BT_TO_COMMON(string),
-               bt_field_type_common_string_destroy,
+       bt_field_type_string_initialize((void *) string,
+               bt_field_type_string_destroy,
                &bt_field_type_string_methods);
        BT_LOGD("Created string field type object: addr=%p", string);
        return (void *) string;
 }
 
-BT_HIDDEN
-enum bt_string_encoding bt_field_type_common_string_get_encoding(
-               struct bt_field_type_common *ft)
+enum bt_string_encoding bt_field_type_string_get_encoding(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_string *string_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_string *string_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_STRING,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_STRING,
                "Field type");
        return string_ft->encoding;
 }
 
-enum bt_string_encoding bt_field_type_string_get_encoding(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_string_get_encoding((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_string_set_encoding(struct bt_field_type_common *ft,
+int bt_field_type_string_set_encoding(struct bt_field_type *ft,
                enum bt_string_encoding encoding)
 {
        int ret = 0;
-       struct bt_field_type_common_string *string_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_string *string_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -3115,14 +2730,7 @@ end:
        return ret;
 }
 
-int bt_field_type_string_set_encoding(struct bt_field_type *ft,
-               enum bt_string_encoding encoding)
-{
-       return bt_field_type_common_string_set_encoding((void *) ft, encoding);
-}
-
-BT_HIDDEN
-int bt_field_type_common_get_alignment(struct bt_field_type_common *ft)
+int bt_field_type_get_alignment(struct bt_field_type *ft)
 {
        int ret;
        enum bt_field_type_id type_id;
@@ -3134,43 +2742,43 @@ int bt_field_type_common_get_alignment(struct bt_field_type_common *ft)
                goto end;
        }
 
-       type_id = bt_field_type_common_get_type_id(ft);
+       type_id = bt_field_type_get_type_id(ft);
        switch (type_id) {
        case BT_FIELD_TYPE_ID_SEQUENCE:
        {
-               struct bt_field_type_common *element_ft =
-                       bt_field_type_common_sequence_borrow_element_field_type(ft);
+               struct bt_field_type *element_ft =
+                       bt_field_type_sequence_borrow_element_field_type(ft);
 
                BT_ASSERT(element_ft);
-               ret = bt_field_type_common_get_alignment(element_ft);
+               ret = bt_field_type_get_alignment(element_ft);
                break;
        }
        case BT_FIELD_TYPE_ID_ARRAY:
        {
-               struct bt_field_type_common *element_ft =
-                       bt_field_type_common_array_borrow_element_field_type(ft);
+               struct bt_field_type *element_ft =
+                       bt_field_type_array_borrow_element_field_type(ft);
 
                BT_ASSERT(element_ft);
-               ret = bt_field_type_common_get_alignment(element_ft);
+               ret = bt_field_type_get_alignment(element_ft);
                break;
        }
        case BT_FIELD_TYPE_ID_STRUCT:
        {
                int64_t i, element_count;
 
-               element_count = bt_field_type_common_structure_get_field_count(
+               element_count = bt_field_type_structure_get_field_count(
                        ft);
                BT_ASSERT(element_count >= 0);
 
                for (i = 0; i < element_count; i++) {
-                       struct bt_field_type_common *field = NULL;
+                       struct bt_field_type *field = NULL;
                        int field_alignment;
 
-                       ret = bt_field_type_common_structure_borrow_field_by_index(
+                       ret = bt_field_type_structure_borrow_field_by_index(
                                ft, NULL, &field, i);
                        BT_ASSERT(ret == 0);
                        BT_ASSERT(field);
-                       field_alignment = bt_field_type_common_get_alignment(
+                       field_alignment = bt_field_type_get_alignment(
                                field);
                        if (field_alignment < 0) {
                                ret = field_alignment;
@@ -3196,19 +2804,13 @@ end:
        return ret;
 }
 
-int bt_field_type_get_alignment(struct bt_field_type *ft)
-{
-       return bt_field_type_common_get_alignment((void *) ft);
-}
-
 static inline
 int is_power_of_two(unsigned int value)
 {
        return ((value & (value - 1)) == 0) && value > 0;
 }
 
-BT_HIDDEN
-int bt_field_type_common_set_alignment(struct bt_field_type_common *ft,
+int bt_field_type_set_alignment(struct bt_field_type *ft,
                unsigned int alignment)
 {
        int ret = 0;
@@ -3235,7 +2837,7 @@ int bt_field_type_common_set_alignment(struct bt_field_type_common *ft,
                goto end;
        }
 
-       type_id = bt_field_type_common_get_type_id(ft);
+       type_id = bt_field_type_get_type_id(ft);
        if (type_id == BT_FIELD_TYPE_ID_UNKNOWN) {
                BT_LOGW("Invalid parameter: unknown field type ID: "
                        "addr=%p, ft-id=%d", ft, type_id);
@@ -3270,15 +2872,7 @@ end:
        return ret;
 }
 
-int bt_field_type_set_alignment(struct bt_field_type *ft,
-               unsigned int alignment)
-{
-       return bt_field_type_common_set_alignment((void *) ft, alignment);
-}
-
-BT_HIDDEN
-enum bt_byte_order bt_field_type_common_get_byte_order(
-               struct bt_field_type_common *ft)
+enum bt_byte_order bt_field_type_get_byte_order(struct bt_field_type *ft)
 {
        enum bt_byte_order ret = BT_BYTE_ORDER_UNKNOWN;
 
@@ -3287,25 +2881,22 @@ enum bt_byte_order bt_field_type_common_get_byte_order(
        switch (ft->id) {
        case BT_FIELD_TYPE_ID_INTEGER:
        {
-               struct bt_field_type_common_integer *integer =
-                       BT_FROM_COMMON(ft);
+               struct bt_field_type_integer *integer = (void *) ft;
 
                ret = integer->user_byte_order;
                break;
        }
        case BT_FIELD_TYPE_ID_ENUM:
        {
-               struct bt_field_type_common_enumeration *enum_ft =
-                       BT_FROM_COMMON(ft);
+               struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
-               ret = bt_field_type_common_get_byte_order(
-                       BT_TO_COMMON(enum_ft->container_ft));
+               ret = bt_field_type_get_byte_order(
+                       (void *) enum_ft->container_ft);
                break;
        }
        case BT_FIELD_TYPE_ID_FLOAT:
        {
-               struct bt_field_type_common_floating_point *floating_point =
-                       BT_FROM_COMMON(ft);
+               struct bt_field_type_floating_point *floating_point = (void *) ft;
                ret = floating_point->user_byte_order;
                break;
        }
@@ -3325,13 +2916,7 @@ end:
        return ret;
 }
 
-enum bt_byte_order bt_field_type_get_byte_order(struct bt_field_type *ft)
-{
-       return bt_field_type_common_get_byte_order((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_set_byte_order(struct bt_field_type_common *ft,
+int bt_field_type_set_byte_order(struct bt_field_type *ft,
                enum bt_byte_order byte_order)
 {
        int ret = 0;
@@ -3371,27 +2956,14 @@ end:
        return ret;
 }
 
-int bt_field_type_set_byte_order(struct bt_field_type *ft,
-               enum bt_byte_order byte_order)
-{
-       return bt_field_type_common_set_byte_order((void *) ft, byte_order);
-}
-
-BT_HIDDEN
-enum bt_field_type_id bt_field_type_common_get_type_id(
-               struct bt_field_type_common *ft)
+enum bt_field_type_id bt_field_type_get_type_id(struct bt_field_type *ft)
 {
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        return ft->id;
 }
 
-enum bt_field_type_id bt_field_type_get_type_id(struct bt_field_type *ft)
-{
-       return bt_field_type_common_get_type_id((void *) ft);
-}
-
 BT_HIDDEN
-void bt_field_type_common_freeze(struct bt_field_type_common *ft)
+void bt_field_type_freeze(struct bt_field_type *ft)
 {
        if (!ft || ft->frozen) {
                return;
@@ -3401,91 +2973,9 @@ void bt_field_type_common_freeze(struct bt_field_type_common *ft)
        ft->methods->freeze(ft);
 }
 
-BT_HIDDEN
-void bt_field_type_freeze(struct bt_field_type *ft)
-{
-       bt_field_type_common_freeze((void *) ft);
-}
-
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_variant_borrow_field_type_signed(
-               struct bt_field_type_common_variant *var_ft,
-               int64_t tag_value)
-{
-       struct bt_field_type_common *field_type = NULL;
-       GQuark field_name_quark;
-       gpointer index;
-       struct bt_field_type_common_variant_choice *choice;
-       struct range_overlap_query query = {
-               .range_start._signed = tag_value,
-               .range_end._signed = tag_value,
-               .mapping_name = 0,
-               .overlaps = 0,
-       };
-
-       g_ptr_array_foreach(var_ft->tag_ft->entries, check_ranges_overlap,
-               &query);
-       if (!query.overlaps) {
-               goto end;
-       }
-
-       field_name_quark = query.mapping_name;
-       if (!g_hash_table_lookup_extended(var_ft->choice_name_to_index,
-                       GUINT_TO_POINTER(field_name_quark), NULL, &index)) {
-               goto end;
-       }
-
-       choice = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(var_ft,
-               (size_t) index);
-       field_type = choice->type;
-
-end:
-       return field_type;
-}
-
-BT_HIDDEN
-struct bt_field_type_common *
-bt_field_type_common_variant_borrow_field_type_unsigned(
-               struct bt_field_type_common_variant *var_ft,
-               uint64_t tag_value)
-{
-       struct bt_field_type_common *field_type = NULL;
-       GQuark field_name_quark;
-       gpointer index;
-       struct bt_field_type_common_variant_choice *choice;
-       struct range_overlap_query query = {
-               .range_start._unsigned = tag_value,
-               .range_end._unsigned = tag_value,
-               .mapping_name = 0,
-               .overlaps = 0,
-       };
-
-       g_ptr_array_foreach(var_ft->tag_ft->entries,
-               check_ranges_overlap_unsigned, &query);
-       if (!query.overlaps) {
-               goto end;
-       }
-
-       field_name_quark = query.mapping_name;
-       if (!g_hash_table_lookup_extended(var_ft->choice_name_to_index,
-               GUINT_TO_POINTER(field_name_quark), NULL, &index)) {
-               goto end;
-       }
-
-       choice = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(var_ft,
-               (size_t) index);
-       field_type = choice->type;
-
-end:
-       return field_type;
-}
-
-BT_HIDDEN
-struct bt_field_type_common *bt_field_type_common_copy(
-               struct bt_field_type_common *ft)
+struct bt_field_type *bt_field_type_copy(struct bt_field_type *ft)
 {
-       struct bt_field_type_common *ft_copy = NULL;
+       struct bt_field_type *ft_copy = NULL;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        BT_ASSERT(ft->methods->copy);
@@ -3501,23 +2991,18 @@ end:
        return ft_copy;
 }
 
-struct bt_field_type *bt_field_type_copy(struct bt_field_type *ft)
-{
-       return (void *) bt_field_type_common_copy((void *) ft);
-}
-
-BT_HIDDEN
-int bt_field_type_common_structure_get_field_name_index(
-               struct bt_field_type_common *ft, const char *name)
+static inline
+int bt_field_type_structure_get_field_name_index(
+               struct bt_field_type *ft, const char *name)
 {
        int ret;
        size_t index;
        GQuark name_quark;
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        BT_ASSERT_PRE_NON_NULL(name, "Name");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_STRUCT,
                "Field type");
 
        name_quark = g_quark_try_string(name);
@@ -3545,18 +3030,18 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_variant_get_field_name_index(
-               struct bt_field_type_common *ft, const char *name)
+static inline
+int bt_field_type_variant_get_field_name_index(
+               struct bt_field_type *ft, const char *name)
 {
        int ret;
        size_t index;
        GQuark name_quark;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
        BT_ASSERT_PRE_NON_NULL(name, "Name");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
        name_quark = g_quark_try_string(name);
        if (!name_quark) {
@@ -3584,11 +3069,11 @@ end:
 }
 
 BT_HIDDEN
-int bt_field_type_common_sequence_set_length_field_path(
-               struct bt_field_type_common *ft, struct bt_field_path *path)
+int bt_field_type_sequence_set_length_field_path(
+               struct bt_field_type *ft, struct bt_field_path *path)
 {
        int ret = 0;
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -3614,12 +3099,12 @@ end:
 }
 
 BT_HIDDEN
-int bt_field_type_common_variant_set_tag_field_path(
-               struct bt_field_type_common *ft,
+int bt_field_type_variant_set_tag_field_path(
+               struct bt_field_type *ft,
                struct bt_field_path *path)
 {
        int ret = 0;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: field type is NULL.");
@@ -3645,12 +3130,12 @@ end:
 }
 
 BT_HIDDEN
-int bt_field_type_common_variant_set_tag_field_type(
-               struct bt_field_type_common *ft,
-               struct bt_field_type_common *tag_ft)
+int bt_field_type_variant_set_tag_field_type(
+               struct bt_field_type *ft,
+               struct bt_field_type *tag_ft)
 {
        int ret = 0;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        if (!ft) {
                BT_LOGW_STR("Invalid parameter: variant field type is NULL.");
@@ -3681,53 +3166,53 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-void bt_field_type_common_generic_freeze(struct bt_field_type_common *ft)
+static
+void bt_field_type_generic_freeze(struct bt_field_type *ft)
 {
        ft->frozen = 1;
 }
 
-BT_HIDDEN
-void bt_field_type_common_enumeration_freeze_recursive(
-               struct bt_field_type_common *ft)
+static
+void bt_field_type_enumeration_freeze_recursive(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
        BT_LOGD("Freezing enumeration field type object: addr=%p", ft);
-       bt_field_type_common_enumeration_set_range_overlap(enum_ft);
-       bt_field_type_common_generic_freeze(ft);
+       bt_field_type_enumeration_set_range_overlap(enum_ft);
+       bt_field_type_generic_freeze(ft);
        BT_LOGD("Freezing enumeration field type object's container field type: int-ft-addr=%p",
                enum_ft->container_ft);
-       bt_field_type_common_freeze(BT_TO_COMMON(enum_ft->container_ft));
+       bt_field_type_freeze((void *) enum_ft->container_ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_structure_freeze_recursive(
-               struct bt_field_type_common *ft)
+static
+void bt_field_type_structure_freeze_recursive(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
        uint64_t i;
 
        /* Cache the alignment */
        BT_LOGD("Freezing structure field type object: addr=%p", ft);
-       ft->alignment = bt_field_type_common_get_alignment(ft);
-       bt_field_type_common_generic_freeze(ft);
+       ft->alignment = bt_field_type_get_alignment(ft);
+       bt_field_type_generic_freeze(ft);
 
        for (i = 0; i < struct_ft->fields->len; i++) {
-               struct bt_field_type_common_structure_field *field =
-                       BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(ft, i);
+               struct bt_field_type_structure_field *field =
+                       BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(ft, i);
 
                BT_LOGD("Freezing structure field type field: "
                        "ft-addr=%p, name=\"%s\"",
                        field->type, g_quark_to_string(field->name));
-               bt_field_type_common_freeze(field->type);
+               bt_field_type_freeze(field->type);
        }
 }
 
 BT_HIDDEN
-int bt_field_type_common_variant_update_choices(struct bt_field_type_common *ft)
+int bt_field_type_variant_update_choices(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
        uint64_t i;
        int ret = 0;
        bool is_signed;
@@ -3740,12 +3225,12 @@ int bt_field_type_common_variant_update_choices(struct bt_field_type_common *ft)
        is_signed = !!var_ft->tag_ft->container_ft->is_signed;
 
        for (i = 0; i < var_ft->choices->len; i++) {
-               struct bt_field_type_common_variant_choice *choice =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(ft, i);
+               struct bt_field_type_variant_choice *choice =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(ft, i);
                const char *choice_name = g_quark_to_string(choice->name);
                struct bt_field_type_enumeration_mapping_iterator *iter =
-                       bt_field_type_common_enumeration_find_mappings_by_name(
-                               BT_TO_COMMON(var_ft->tag_ft), choice_name);
+                       bt_field_type_enumeration_find_mappings_by_name(
+                               (void *) var_ft->tag_ft, choice_name);
 
                if (!iter) {
                        ret = -1;
@@ -3756,7 +3241,7 @@ int bt_field_type_common_variant_update_choices(struct bt_field_type_common *ft)
                g_array_set_size(choice->ranges, 0);
 
                while (bt_field_type_enumeration_mapping_iterator_next(iter) == 0) {
-                       struct bt_field_type_common_variant_choice_range range;
+                       struct bt_field_type_variant_choice_range range;
 
                        if (is_signed) {
                                ret = bt_field_type_enumeration_mapping_iterator_signed_get(
@@ -3781,149 +3266,149 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-void bt_field_type_common_variant_freeze_recursive(
-               struct bt_field_type_common *ft)
+static
+void bt_field_type_variant_freeze_recursive(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
        uint64_t i;
 
        BT_LOGD("Freezing variant field type object: addr=%p", ft);
-       bt_field_type_common_generic_freeze(ft);
+       bt_field_type_generic_freeze(ft);
 
        for (i = 0; i < var_ft->choices->len; i++) {
-               struct bt_field_type_common_variant_choice *choice =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(ft, i);
+               struct bt_field_type_variant_choice *choice =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(ft, i);
 
                BT_LOGD("Freezing variant field type member: "
                        "ft-addr=%p, name=\"%s\"",
                        choice->type, g_quark_to_string(choice->name));
-               bt_field_type_common_freeze(choice->type);
+               bt_field_type_freeze(choice->type);
        }
 }
 
-BT_HIDDEN
-void bt_field_type_common_array_freeze_recursive(
-               struct bt_field_type_common *ft)
+static
+void bt_field_type_array_freeze_recursive(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
 
        /* Cache the alignment */
        BT_LOGD("Freezing array field type object: addr=%p", ft);
-       ft->alignment = bt_field_type_common_get_alignment(ft);
-       bt_field_type_common_generic_freeze(ft);
+       ft->alignment = bt_field_type_get_alignment(ft);
+       bt_field_type_generic_freeze(ft);
        BT_LOGD("Freezing array field type object's element field type: element-ft-addr=%p",
                array_ft->element_ft);
-       bt_field_type_common_freeze(array_ft->element_ft);
+       bt_field_type_freeze(array_ft->element_ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_sequence_freeze_recursive(
-               struct bt_field_type_common *ft)
+static
+void bt_field_type_sequence_freeze_recursive(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        /* Cache the alignment */
        BT_LOGD("Freezing sequence field type object: addr=%p", ft);
-       ft->alignment = bt_field_type_common_get_alignment(ft);
-       bt_field_type_common_generic_freeze(ft);
+       ft->alignment = bt_field_type_get_alignment(ft);
+       bt_field_type_generic_freeze(ft);
        BT_LOGD("Freezing sequence field type object's element field type: element-ft-addr=%p",
                seq_ft->element_ft);
-       bt_field_type_common_freeze(seq_ft->element_ft);
+       bt_field_type_freeze(seq_ft->element_ft);
 }
 
-BT_HIDDEN
-void bt_field_type_common_integer_set_byte_order(
-               struct bt_field_type_common *ft, enum bt_byte_order byte_order)
+static
+void bt_field_type_integer_set_byte_order(
+               struct bt_field_type *ft, enum bt_byte_order byte_order)
 {
-       struct bt_field_type_common_integer *int_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_integer *int_ft = (void *) ft;
 
        int_ft->user_byte_order = byte_order;
 }
 
-BT_HIDDEN
-void bt_field_type_common_enumeration_set_byte_order_recursive(
-               struct bt_field_type_common *ft, enum bt_byte_order byte_order)
+static
+void bt_field_type_enumeration_set_byte_order_recursive(
+               struct bt_field_type *ft, enum bt_byte_order byte_order)
 {
-       struct bt_field_type_common_enumeration *enum_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
 
-       bt_field_type_common_set_byte_order(BT_TO_COMMON(enum_ft->container_ft),
+       bt_field_type_set_byte_order((void *) enum_ft->container_ft,
                byte_order);
 }
 
-BT_HIDDEN
-void bt_field_type_common_floating_point_set_byte_order(
-               struct bt_field_type_common *ft, enum bt_byte_order byte_order)
+static
+void bt_field_type_floating_point_set_byte_order(
+               struct bt_field_type *ft, enum bt_byte_order byte_order)
 {
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
 
        flt_ft->user_byte_order = byte_order;
 }
 
-BT_HIDDEN
-void bt_field_type_common_structure_set_byte_order_recursive(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_structure_set_byte_order_recursive(
+               struct bt_field_type *ft,
                enum bt_byte_order byte_order)
 {
        int i;
-       struct bt_field_type_common_structure *struct_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_structure *struct_ft = (void *) ft;
 
        for (i = 0; i < struct_ft->fields->len; i++) {
-               struct bt_field_type_common_structure_field *field =
-                       BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+               struct bt_field_type_structure_field *field =
+                       BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                                struct_ft, i);
-               struct bt_field_type_common *field_type = field->type;
+               struct bt_field_type *field_type = field->type;
 
-               bt_field_type_common_set_byte_order(field_type, byte_order);
+               bt_field_type_set_byte_order(field_type, byte_order);
        }
 }
 
-BT_HIDDEN
-void bt_field_type_common_variant_set_byte_order_recursive(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_variant_set_byte_order_recursive(
+               struct bt_field_type *ft,
                enum bt_byte_order byte_order)
 {
        int i;
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        for (i = 0; i < var_ft->choices->len; i++) {
-               struct bt_field_type_common_variant_choice *choice =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+               struct bt_field_type_variant_choice *choice =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                                var_ft, i);
-               struct bt_field_type_common *field_type = choice->type;
+               struct bt_field_type *field_type = choice->type;
 
-               bt_field_type_common_set_byte_order(field_type, byte_order);
+               bt_field_type_set_byte_order(field_type, byte_order);
        }
 }
 
-BT_HIDDEN
-void bt_field_type_common_array_set_byte_order_recursive(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_array_set_byte_order_recursive(
+               struct bt_field_type *ft,
                enum bt_byte_order byte_order)
 {
-       struct bt_field_type_common_array *array_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_array *array_ft = (void *) ft;
 
-       bt_field_type_common_set_byte_order(array_ft->element_ft, byte_order);
+       bt_field_type_set_byte_order(array_ft->element_ft, byte_order);
 }
 
-BT_HIDDEN
-void bt_field_type_common_sequence_set_byte_order_recursive(
-               struct bt_field_type_common *ft,
+static
+void bt_field_type_sequence_set_byte_order_recursive(
+               struct bt_field_type *ft,
                enum bt_byte_order byte_order)
 {
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
-       bt_field_type_common_set_byte_order(seq_ft->element_ft, byte_order);
+       bt_field_type_set_byte_order(seq_ft->element_ft, byte_order);
 }
 
 
-BT_HIDDEN
-int bt_field_type_common_integer_compare(struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_integer_compare(struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
-       struct bt_field_type_common_integer *int_ft_a = BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_integer *int_ft_b = BT_FROM_COMMON(ft_b);
+       struct bt_field_type_integer *int_ft_a = (void *) ft_a;
+       struct bt_field_type_integer *int_ft_b = (void *) ft_b;
 
        /* Length */
        if (int_ft_a->size != int_ft_b->size) {
@@ -3998,16 +3483,14 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_floating_point_compare(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_floating_point_compare(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
-       struct bt_field_type_common_floating_point *flt_ft_a =
-               BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_floating_point *flt_ft_b =
-               BT_FROM_COMMON(ft_b);
+       struct bt_field_type_floating_point *flt_ft_a = (void *) ft_a;
+       struct bt_field_type_floating_point *flt_ft_b = (void *) ft_b;
 
        /* Byte order */
        if (flt_ft_a->user_byte_order != flt_ft_b->user_byte_order) {
@@ -4085,22 +3568,19 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_enumeration_compare_recursive(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_enumeration_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
        int i;
-       struct bt_field_type_common_enumeration *enum_ft_a =
-               BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_enumeration *enum_ft_b =
-               BT_FROM_COMMON(ft_b);
+       struct bt_field_type_enumeration *enum_ft_a = (void *) ft_a;
+       struct bt_field_type_enumeration *enum_ft_b = (void *) ft_b;
 
        /* Container field type */
-       ret = bt_field_type_common_compare(
-               BT_TO_COMMON(enum_ft_a->container_ft),
-               BT_TO_COMMON(enum_ft_b->container_ft));
+       ret = bt_field_type_compare((void *) enum_ft_a->container_ft,
+               (void *) enum_ft_b->container_ft);
        if (ret) {
                BT_LOGV("Enumeration field types differ: different container field types: "
                        "ft-a-container-ft-addr=%p, ft-b-container-ft-addr=%p",
@@ -4139,13 +3619,13 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_string_compare(struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_string_compare(struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
-       struct bt_field_type_common_string *string_ft_a = BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_string *string_ft_b = BT_FROM_COMMON(ft_b);
+       struct bt_field_type_string *string_ft_a = (void *) ft_a;
+       struct bt_field_type_string *string_ft_b = (void *) ft_b;
 
        /* Encoding */
        if (string_ft_a->encoding != string_ft_b->encoding) {
@@ -4165,8 +3645,8 @@ end:
 
 static
 int compare_structure_variant_members(
-               struct bt_field_type_common *member_a_ft,
-               struct bt_field_type_common *member_b_ft,
+               struct bt_field_type *member_a_ft,
+               struct bt_field_type *member_b_ft,
                GQuark member_a_name, GQuark member_b_name)
 {
        int ret = 1;
@@ -4181,7 +3661,7 @@ int compare_structure_variant_members(
        }
 
        /* Type */
-       ret = bt_field_type_common_compare(member_a_ft, member_b_ft);
+       ret = bt_field_type_compare(member_a_ft, member_b_ft);
        if (ret == 1) {
                BT_LOGV("Structure/variant field type fields differ: different field types: "
                        "field-name=\"%s\", field-a-ft-addr=%p, field-b-ft-addr=%p",
@@ -4193,25 +3673,23 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_structure_compare_recursive(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_structure_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
        int i;
-       struct bt_field_type_common_structure *struct_ft_a =
-               BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_structure *struct_ft_b =
-               BT_FROM_COMMON(ft_b);
+       struct bt_field_type_structure *struct_ft_a = (void *) ft_a;
+       struct bt_field_type_structure *struct_ft_b = (void *) ft_b;
 
        /* Alignment */
-       if (bt_field_type_common_get_alignment(ft_a) !=
-                       bt_field_type_common_get_alignment(ft_b)) {
+       if (bt_field_type_get_alignment(ft_a) !=
+                       bt_field_type_get_alignment(ft_b)) {
                BT_LOGV("Structure field types differ: different alignments: "
                        "ft-a-align=%u, ft-b-align=%u",
-                       bt_field_type_common_get_alignment(ft_a),
-                       bt_field_type_common_get_alignment(ft_b));
+                       bt_field_type_get_alignment(ft_a),
+                       bt_field_type_get_alignment(ft_b));
                goto end;
        }
 
@@ -4224,11 +3702,11 @@ int bt_field_type_common_structure_compare_recursive(
        }
 
        for (i = 0; i < struct_ft_a->fields->len; ++i) {
-               struct bt_field_type_common_structure_field *field_a =
-                       BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+               struct bt_field_type_structure_field *field_a =
+                       BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                                struct_ft_a, i);
-               struct bt_field_type_common_structure_field *field_b =
-                       BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+               struct bt_field_type_structure_field *field_b =
+                       BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                                struct_ft_b, i);
 
                ret = compare_structure_variant_members(field_a->type,
@@ -4247,15 +3725,15 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_variant_compare_recursive(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_variant_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
        int i;
-       struct bt_field_type_common_variant *var_ft_a = BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_variant *var_ft_b = BT_FROM_COMMON(ft_b);
+       struct bt_field_type_variant *var_ft_a = (void *) ft_a;
+       struct bt_field_type_variant *var_ft_b = (void *) ft_b;
 
        /* Tag name */
        if (strcmp(var_ft_a->tag_name->str, var_ft_b->tag_name->str)) {
@@ -4266,8 +3744,8 @@ int bt_field_type_common_variant_compare_recursive(
        }
 
        /* Tag type */
-       ret = bt_field_type_common_compare(BT_TO_COMMON(var_ft_a->tag_ft),
-               BT_TO_COMMON(var_ft_b->tag_ft));
+       ret = bt_field_type_compare((void *) var_ft_a->tag_ft,
+               (void *) var_ft_b->tag_ft);
        if (ret) {
                BT_LOGV("Variant field types differ: different tag field types: "
                        "ft-a-tag-ft-addr=%p, ft-b-tag-ft-addr=%p",
@@ -4286,11 +3764,11 @@ int bt_field_type_common_variant_compare_recursive(
        }
 
        for (i = 0; i < var_ft_a->choices->len; ++i) {
-               struct bt_field_type_common_variant_choice *choice_a =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+               struct bt_field_type_variant_choice *choice_a =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                                var_ft_a, i);
-               struct bt_field_type_common_variant_choice *choice_b =
-                       BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+               struct bt_field_type_variant_choice *choice_b =
+                       BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                                var_ft_b, i);
 
                ret = compare_structure_variant_members(choice_a->type,
@@ -4309,14 +3787,14 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_array_compare_recursive(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_array_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
-       struct bt_field_type_common_array *array_ft_a = BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_array *array_ft_b = BT_FROM_COMMON(ft_b);
+       struct bt_field_type_array *array_ft_a = (void *) ft_a;
+       struct bt_field_type_array *array_ft_b = (void *) ft_b;
 
        /* Length */
        if (array_ft_a->length != array_ft_b->length) {
@@ -4327,7 +3805,7 @@ int bt_field_type_common_array_compare_recursive(
        }
 
        /* Element type */
-       ret = bt_field_type_common_compare(array_ft_a->element_ft,
+       ret = bt_field_type_compare(array_ft_a->element_ft,
                array_ft_b->element_ft);
        if (ret == 1) {
                BT_LOGV("Array field types differ: different element field types: "
@@ -4339,14 +3817,14 @@ end:
        return ret;
 }
 
-BT_HIDDEN
-int bt_field_type_common_sequence_compare_recursive(
-               struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+static
+int bt_field_type_sequence_compare_recursive(
+               struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = -1;
-       struct bt_field_type_common_sequence *seq_ft_a = BT_FROM_COMMON(ft_a);
-       struct bt_field_type_common_sequence *seq_ft_b = BT_FROM_COMMON(ft_b);
+       struct bt_field_type_sequence *seq_ft_a = (void *) ft_a;
+       struct bt_field_type_sequence *seq_ft_b = (void *) ft_b;
 
        /* Length name */
        if (strcmp(seq_ft_a->length_field_name->str,
@@ -4360,7 +3838,7 @@ int bt_field_type_common_sequence_compare_recursive(
        }
 
        /* Element type */
-       ret = bt_field_type_common_compare(seq_ft_a->element_ft,
+       ret = bt_field_type_compare(seq_ft_a->element_ft,
                        seq_ft_b->element_ft);
        if (ret == 1) {
                BT_LOGV("Sequence field types differ: different element field types: "
@@ -4373,8 +3851,8 @@ end:
 }
 
 BT_HIDDEN
-int bt_field_type_common_compare(struct bt_field_type_common *ft_a,
-               struct bt_field_type_common *ft_b)
+int bt_field_type_compare(struct bt_field_type *ft_a,
+               struct bt_field_type *ft_b)
 {
        int ret = 1;
 
@@ -4427,25 +3905,19 @@ end:
        return ret;
 }
 
-int bt_field_type_compare(struct bt_field_type *ft_a,
-               struct bt_field_type *ft_b)
-{
-       return bt_field_type_common_compare((void *) ft_a, (void *) ft_b);
-}
-
 BT_HIDDEN
-int64_t bt_field_type_common_get_field_count(struct bt_field_type_common *ft)
+int64_t bt_field_type_get_field_count(struct bt_field_type *ft)
 {
        int64_t field_count = -1;
 
        switch (ft->id) {
        case BT_FIELD_TYPE_ID_STRUCT:
                field_count =
-                       bt_field_type_common_structure_get_field_count(ft);
+                       bt_field_type_structure_get_field_count(ft);
                break;
        case BT_FIELD_TYPE_ID_VARIANT:
                field_count =
-                       bt_field_type_common_variant_get_field_count(ft);
+                       bt_field_type_variant_get_field_count(ft);
                break;
        case BT_FIELD_TYPE_ID_ARRAY:
        case BT_FIELD_TYPE_ID_SEQUENCE:
@@ -4463,15 +3935,15 @@ int64_t bt_field_type_common_get_field_count(struct bt_field_type_common *ft)
 }
 
 BT_HIDDEN
-struct bt_field_type_common *bt_field_type_common_borrow_field_at_index(
-               struct bt_field_type_common *ft, int index)
+struct bt_field_type *bt_field_type_borrow_field_at_index(
+               struct bt_field_type *ft, int index)
 {
-       struct bt_field_type_common *field_type = NULL;
+       struct bt_field_type *field_type = NULL;
 
        switch (ft->id) {
        case BT_FIELD_TYPE_ID_STRUCT:
        {
-               int ret = bt_field_type_common_structure_borrow_field_by_index(
+               int ret = bt_field_type_structure_borrow_field_by_index(
                        ft, NULL, &field_type, index);
                if (ret) {
                        field_type = NULL;
@@ -4481,7 +3953,7 @@ struct bt_field_type_common *bt_field_type_common_borrow_field_at_index(
        }
        case BT_FIELD_TYPE_ID_VARIANT:
        {
-               int ret = bt_field_type_common_variant_borrow_field_by_index(
+               int ret = bt_field_type_variant_borrow_field_by_index(
                        ft, NULL, &field_type, index);
                if (ret) {
                        field_type = NULL;
@@ -4491,11 +3963,11 @@ struct bt_field_type_common *bt_field_type_common_borrow_field_at_index(
        }
        case BT_FIELD_TYPE_ID_ARRAY:
                field_type =
-                       bt_field_type_common_array_borrow_element_field_type(ft);
+                       bt_field_type_array_borrow_element_field_type(ft);
                break;
        case BT_FIELD_TYPE_ID_SEQUENCE:
                field_type =
-                       bt_field_type_common_sequence_borrow_element_field_type(ft);
+                       bt_field_type_sequence_borrow_element_field_type(ft);
                break;
        default:
                break;
@@ -4506,18 +3978,18 @@ end:
 }
 
 BT_HIDDEN
-int bt_field_type_common_get_field_index(struct bt_field_type_common *ft,
+int bt_field_type_get_field_index(struct bt_field_type *ft,
                const char *name)
 {
        int field_index = -1;
 
        switch (ft->id) {
        case BT_FIELD_TYPE_ID_STRUCT:
-               field_index = bt_field_type_common_structure_get_field_name_index(
+               field_index = bt_field_type_structure_get_field_name_index(
                        ft, name);
                break;
        case BT_FIELD_TYPE_ID_VARIANT:
-               field_index = bt_field_type_common_variant_get_field_name_index(
+               field_index = bt_field_type_variant_get_field_name_index(
                        ft, name);
                break;
        default:
@@ -4527,46 +3999,31 @@ int bt_field_type_common_get_field_index(struct bt_field_type_common *ft,
        return field_index;
 }
 
-BT_HIDDEN
-struct bt_field_path *bt_field_type_common_variant_borrow_tag_field_path(
-               struct bt_field_type_common *ft)
+struct bt_field_path *bt_field_type_variant_borrow_tag_field_path(
+               struct bt_field_type *ft)
 {
-       struct bt_field_type_common_variant *var_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_variant *var_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_VARIANT,
                "Field type");
        return var_ft->tag_field_path;
 }
 
-struct bt_field_path *bt_field_type_variant_borrow_tag_field_path(
+struct bt_field_path *bt_field_type_sequence_borrow_length_field_path(
                struct bt_field_type *ft)
 {
-       return bt_field_type_common_variant_borrow_tag_field_path((void *) ft);
-}
-
-BT_HIDDEN
-struct bt_field_path *bt_field_type_common_sequence_borrow_length_field_path(
-               struct bt_field_type_common *ft)
-{
-       struct bt_field_type_common_sequence *seq_ft = BT_FROM_COMMON(ft);
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
 
        BT_ASSERT_PRE_NON_NULL(ft, "Field type");
-       BT_ASSERT_PRE_FT_COMMON_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
+       BT_ASSERT_PRE_FT_HAS_ID(ft, BT_FIELD_TYPE_ID_SEQUENCE,
                "Field type");
        return seq_ft->length_field_path;
 }
 
-struct bt_field_path *bt_field_type_sequence_borrow_length_field_path(
-               struct bt_field_type *ft)
-{
-       return bt_field_type_common_sequence_borrow_length_field_path(
-               (void *) ft);
-}
-
 BT_HIDDEN
-int bt_field_type_common_validate_single_clock_class(
-               struct bt_field_type_common *ft,
+int bt_field_type_validate_single_clock_class(
+               struct bt_field_type *ft,
                struct bt_clock_class **expected_clock_class)
 {
        int ret = 0;
@@ -4581,7 +4038,7 @@ int bt_field_type_common_validate_single_clock_class(
        case BT_FIELD_TYPE_ID_INTEGER:
        {
                struct bt_clock_class *mapped_clock_class =
-                       bt_field_type_common_integer_borrow_mapped_clock_class(ft);
+                       bt_field_type_integer_borrow_mapped_clock_class(ft);
 
                if (!mapped_clock_class) {
                        goto end;
@@ -4618,19 +4075,19 @@ int bt_field_type_common_validate_single_clock_class(
        case BT_FIELD_TYPE_ID_ARRAY:
        case BT_FIELD_TYPE_ID_SEQUENCE:
        {
-               struct bt_field_type_common *sub_ft = NULL;
+               struct bt_field_type *sub_ft = NULL;
 
                switch (ft->id) {
                case BT_FIELD_TYPE_ID_ENUM:
-                       sub_ft = bt_field_type_common_enumeration_borrow_container_field_type(
+                       sub_ft = bt_field_type_enumeration_borrow_container_field_type(
                                ft);
                        break;
                case BT_FIELD_TYPE_ID_ARRAY:
-                       sub_ft = bt_field_type_common_array_borrow_element_field_type(
+                       sub_ft = bt_field_type_array_borrow_element_field_type(
                                ft);
                        break;
                case BT_FIELD_TYPE_ID_SEQUENCE:
-                       sub_ft = bt_field_type_common_sequence_borrow_element_field_type(
+                       sub_ft = bt_field_type_sequence_borrow_element_field_type(
                                ft);
                        break;
                default:
@@ -4639,24 +4096,24 @@ int bt_field_type_common_validate_single_clock_class(
                }
 
                BT_ASSERT(sub_ft);
-               ret = bt_field_type_common_validate_single_clock_class(sub_ft,
+               ret = bt_field_type_validate_single_clock_class(sub_ft,
                        expected_clock_class);
                break;
        }
        case BT_FIELD_TYPE_ID_STRUCT:
        {
                uint64_t i;
-               int64_t count = bt_field_type_common_structure_get_field_count(
+               int64_t count = bt_field_type_structure_get_field_count(
                        ft);
 
                for (i = 0; i < count; i++) {
                        const char *name;
-                       struct bt_field_type_common *member_type;
+                       struct bt_field_type *member_type;
 
-                       ret = bt_field_type_common_structure_borrow_field_by_index(
+                       ret = bt_field_type_structure_borrow_field_by_index(
                                ft, &name, &member_type, i);
                        BT_ASSERT(ret == 0);
-                       ret = bt_field_type_common_validate_single_clock_class(
+                       ret = bt_field_type_validate_single_clock_class(
                                member_type, expected_clock_class);
                        if (ret) {
                                BT_LOGW("Structure field type's field's type "
@@ -4672,17 +4129,17 @@ int bt_field_type_common_validate_single_clock_class(
        case BT_FIELD_TYPE_ID_VARIANT:
        {
                uint64_t i;
-               int64_t count = bt_field_type_common_variant_get_field_count(
+               int64_t count = bt_field_type_variant_get_field_count(
                        ft);
 
                for (i = 0; i < count; i++) {
                        const char *name;
-                       struct bt_field_type_common *member_type;
+                       struct bt_field_type *member_type;
 
-                       ret = bt_field_type_common_variant_borrow_field_by_index(
+                       ret = bt_field_type_variant_borrow_field_by_index(
                                ft, &name, &member_type, i);
                        BT_ASSERT(ret == 0);
-                       ret = bt_field_type_common_validate_single_clock_class(
+                       ret = bt_field_type_validate_single_clock_class(
                                member_type, expected_clock_class);
                        if (ret) {
                                BT_LOGW("Variant field type's field's type "
@@ -4707,8 +4164,8 @@ static
 struct bt_field_type *bt_field_type_integer_copy(
                struct bt_field_type *ft)
 {
-       struct bt_field_type_common_integer *int_ft = (void *) ft;
-       struct bt_field_type_common_integer *copy_ft;
+       struct bt_field_type_integer *int_ft = (void *) ft;
+       struct bt_field_type_integer *copy_ft;
 
        BT_LOGD("Copying integer field type's: addr=%p", ft);
        copy_ft = (void *) bt_field_type_integer_create(int_ft->size);
@@ -4735,16 +4192,16 @@ struct bt_field_type *bt_field_type_enumeration_copy_recursive(
                struct bt_field_type *ft)
 {
        size_t i;
-       struct bt_field_type_common_enumeration *enum_ft = (void *) ft;
-       struct bt_field_type_common_enumeration *copy_ft = NULL;
-       struct bt_field_type_common_enumeration *container_copy_ft;
+       struct bt_field_type_enumeration *enum_ft = (void *) ft;
+       struct bt_field_type_enumeration *copy_ft = NULL;
+       struct bt_field_type_enumeration *container_copy_ft;
 
        BT_LOGD("Copying enumeration field type's: addr=%p", ft);
 
        /* Copy the source enumeration's container */
        BT_LOGD_STR("Copying enumeration field type's container field type.");
-       container_copy_ft = BT_FROM_COMMON(bt_field_type_common_copy(
-               BT_TO_COMMON(enum_ft->container_ft)));
+       container_copy_ft =
+               (void *) bt_field_type_copy((void *) enum_ft->container_ft);
        if (!container_copy_ft) {
                BT_LOGE_STR("Cannot copy enumeration field type's container field type.");
                goto end;
@@ -4790,8 +4247,8 @@ static
 struct bt_field_type *bt_field_type_floating_point_copy(
                struct bt_field_type *ft)
 {
-       struct bt_field_type_common_floating_point *flt_ft = BT_FROM_COMMON(ft);
-       struct bt_field_type_common_floating_point *copy_ft;
+       struct bt_field_type_floating_point *flt_ft = (void *) ft;
+       struct bt_field_type_floating_point *copy_ft;
 
        BT_LOGD("Copying floating point number field type's: addr=%p", ft);
        copy_ft = (void *) bt_field_type_floating_point_create();
@@ -4817,8 +4274,8 @@ struct bt_field_type *bt_field_type_structure_copy_recursive(
        int64_t i;
        GHashTableIter iter;
        gpointer key, value;
-       struct bt_field_type_common_structure *struct_ft = (void *) ft;
-       struct bt_field_type_common_structure *copy_ft;
+       struct bt_field_type_structure *struct_ft = (void *) ft;
+       struct bt_field_type_structure *copy_ft;
 
        BT_LOGD("Copying structure field type's: addr=%p", ft);
        copy_ft = (void *) bt_field_type_structure_create();
@@ -4837,12 +4294,12 @@ struct bt_field_type *bt_field_type_structure_copy_recursive(
        g_array_set_size(copy_ft->fields, struct_ft->fields->len);
 
        for (i = 0; i < struct_ft->fields->len; i++) {
-               struct bt_field_type_common_structure_field *entry, *copy_entry;
-               struct bt_field_type_common *field_ft_copy;
+               struct bt_field_type_structure_field *entry, *copy_entry;
+               struct bt_field_type *field_ft_copy;
 
-               entry = BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+               entry = BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                        struct_ft, i);
-               copy_entry = BT_FIELD_TYPE_COMMON_STRUCTURE_FIELD_AT_INDEX(
+               copy_entry = BT_FIELD_TYPE_STRUCTURE_FIELD_AT_INDEX(
                        copy_ft, i);
                BT_LOGD("Copying structure field type's field: "
                        "index=%" PRId64 ", "
@@ -4881,15 +4338,14 @@ struct bt_field_type *bt_field_type_variant_copy_recursive(
        int64_t i;
        GHashTableIter iter;
        gpointer key, value;
-       struct bt_field_type_common *tag_ft_copy = NULL;
-       struct bt_field_type_common_variant *var_ft = (void *) ft;
-       struct bt_field_type_common_variant *copy_ft = NULL;
+       struct bt_field_type *tag_ft_copy = NULL;
+       struct bt_field_type_variant *var_ft = (void *) ft;
+       struct bt_field_type_variant *copy_ft = NULL;
 
        BT_LOGD("Copying variant field type's: addr=%p", ft);
        if (var_ft->tag_ft) {
                BT_LOGD_STR("Copying variant field type's tag field type.");
-               tag_ft_copy = bt_field_type_common_copy(
-                       BT_TO_COMMON(var_ft->tag_ft));
+               tag_ft_copy = bt_field_type_copy((void *) var_ft->tag_ft);
                if (!tag_ft_copy) {
                        BT_LOGE_STR("Cannot copy variant field type's tag field type.");
                        goto end;
@@ -4914,12 +4370,12 @@ struct bt_field_type *bt_field_type_variant_copy_recursive(
        g_array_set_size(copy_ft->choices, var_ft->choices->len);
 
        for (i = 0; i < var_ft->choices->len; i++) {
-               struct bt_field_type_common_variant_choice *entry, *copy_entry;
-               struct bt_field_type_common *field_ft_copy;
+               struct bt_field_type_variant_choice *entry, *copy_entry;
+               struct bt_field_type *field_ft_copy;
                uint64_t range_i;
 
-               entry = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(var_ft, i);
-               copy_entry = BT_FIELD_TYPE_COMMON_VARIANT_CHOICE_AT_INDEX(
+               entry = BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(var_ft, i);
+               copy_entry = BT_FIELD_TYPE_VARIANT_CHOICE_AT_INDEX(
                        copy_ft, i);
                BT_LOGD("Copying variant field type's field: "
                        "index=%" PRId64 ", "
@@ -4942,7 +4398,7 @@ struct bt_field_type *bt_field_type_variant_copy_recursive(
 
                /* Copy ranges */
                copy_entry->ranges = g_array_new(FALSE, TRUE,
-                       sizeof(struct bt_field_type_common_variant_choice_range));
+                       sizeof(struct bt_field_type_variant_choice_range));
                BT_ASSERT(copy_entry->ranges);
                g_array_set_size(copy_entry->ranges, entry->ranges->len);
 
@@ -4979,13 +4435,13 @@ static
 struct bt_field_type *bt_field_type_array_copy_recursive(
                struct bt_field_type *ft)
 {
-       struct bt_field_type_common *container_ft_copy = NULL;
-       struct bt_field_type_common_array *array_ft = (void *) ft;
-       struct bt_field_type_common_array *copy_ft = NULL;
+       struct bt_field_type *container_ft_copy = NULL;
+       struct bt_field_type_array *array_ft = (void *) ft;
+       struct bt_field_type_array *copy_ft = NULL;
 
        BT_LOGD("Copying array field type's: addr=%p", ft);
        BT_LOGD_STR("Copying array field type's element field type.");
-       container_ft_copy = bt_field_type_common_copy(array_ft->element_ft);
+       container_ft_copy = bt_field_type_copy(array_ft->element_ft);
        if (!container_ft_copy) {
                BT_LOGE_STR("Cannot copy array field type's element field type.");
                goto end;
@@ -5010,13 +4466,13 @@ static
 struct bt_field_type *bt_field_type_sequence_copy_recursive(
                struct bt_field_type *ft)
 {
-       struct bt_field_type_common *container_ft_copy = NULL;
-       struct bt_field_type_common_sequence *seq_ft = (void *) ft;
-       struct bt_field_type_common_sequence *copy_ft = NULL;
+       struct bt_field_type *container_ft_copy = NULL;
+       struct bt_field_type_sequence *seq_ft = (void *) ft;
+       struct bt_field_type_sequence *copy_ft = NULL;
 
        BT_LOGD("Copying sequence field type's: addr=%p", ft);
        BT_LOGD_STR("Copying sequence field type's element field type.");
-       container_ft_copy = bt_field_type_common_copy(seq_ft->element_ft);
+       container_ft_copy = bt_field_type_copy(seq_ft->element_ft);
        if (!container_ft_copy) {
                BT_LOGE_STR("Cannot copy sequence field type's element field type.");
                goto end;
@@ -5056,8 +4512,8 @@ error:
 static
 struct bt_field_type *bt_field_type_string_copy(struct bt_field_type *ft)
 {
-       struct bt_field_type_common_string *string_ft = (void *) ft;
-       struct bt_field_type_common_string *copy_ft = NULL;
+       struct bt_field_type_string *string_ft = (void *) ft;
+       struct bt_field_type_string *copy_ft = NULL;
 
        BT_LOGD("Copying string field type's: addr=%p", ft);
        copy_ft = (void *) bt_field_type_string_create();
This page took 0.123021 seconds and 4 git commands to generate.