core: Make type->packed_attributes_inferred a one bit member

To make up space, it is not that much used.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
Arnaldo Carvalho de Melo 2022-02-08 15:18:53 -03:00
parent fac821246c
commit 0a82f74ce2
2 changed files with 5 additions and 5 deletions

View File

@ -1607,7 +1607,7 @@ void type__check_structs_at_unnatural_alignments(struct type *type, const struct
struct class *cls = tag__class(member_type);
cls->is_packed = true;
cls->type.packed_attributes_inferred = true;
cls->type.packed_attributes_inferred = 1;
}
}
}
@ -1663,7 +1663,7 @@ bool class__infer_packed_attributes(struct class *cls, const struct cu *cu)
cls->is_packed = true;
out:
ctype->packed_attributes_inferred = true;
ctype->packed_attributes_inferred = 1;
return cls->is_packed;
}
@ -1695,11 +1695,11 @@ void union__infer_packed_attributes(struct type *type, const struct cu *cu)
struct class *cls = tag__class(member_type);
cls->is_packed = true;
cls->type.packed_attributes_inferred = true;
cls->type.packed_attributes_inferred = 1;
}
}
type->packed_attributes_inferred = true;
type->packed_attributes_inferred = 1;
}
/** class__has_hole_ge - check if class has a hole greater or equal to @size

View File

@ -1038,7 +1038,7 @@ struct type {
uint16_t member_prefix_len;
uint16_t max_tag_name_len;
uint16_t natural_alignment;
bool packed_attributes_inferred;
uint8_t packed_attributes_inferred:1;
uint8_t declaration:1;
uint8_t definition_emitted:1;
uint8_t fwd_decl_emitted:1;