ir_type *points_to; /**< The type of the ir_entity the pointer points to. */
} ptr_attr;
-/*
-typedef struct { * No private attr yet! *
-} pri_attr; */
+/** Primitive type attributes. */
+typedef struct {
+ ir_type *base_type; /**< For bitfield types: The base primitive type, NULL else. */
+} pri_attr;
/*
arr_attr aa; /**< Attributes of an array type */
enm_attr ea; /**< Attributes of an enumeration type */
ptr_attr pa; /**< Attributes of a pointer type */
+ pri_attr ba; /**< Attributes of a primitive bitfield type */
} tp_attr;
/** Additional type flags. */
return size >> 3;
}
-static INLINE type_state
+static INLINE ir_type_state
_get_type_state(const ir_type *tp) {
assert(tp && tp->kind == k_type);
return tp->flags & tf_layout_fixed ? layout_fixed : layout_undefined;
return tp->visit < firm_type_visited;
}
+static INLINE dbg_info *
+_get_type_dbg_info(const ir_type *tp) {
+ return tp->dbi;
+}
+
+static INLINE void
+_set_type_dbg_info(ir_type *tp, dbg_info *db) {
+ tp->dbi = db;
+}
+
static INLINE int
_is_type(const void *thing) {
return (get_kind(thing) == k_type);
method->attr.ma.irg_calling_conv = cc_mask;
}
+
#define set_master_type_visited(val) _set_master_type_visited(val)
#define get_master_type_visited() _get_master_type_visited()
#define inc_master_type_visited() _inc_master_type_visited()
#define mark_type_visited(tp) _mark_type_visited(tp)
#define type_visited(tp) _type_visited(tp)
#define type_not_visited(tp) _type_not_visited(tp)
+#define get_type_dbg_info(tp) _get_type_dbg_info(tp)
+#define set_type_dbg_info(tp, db) _set_type_dbg_info(tp, db)
#define is_type(thing) _is_type(thing)
#define is_Class_type(clss) _is_class_type(clss)
#define get_class_n_members(clss) _get_class_n_members(clss)