mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
More correct alignment. Foreach added. Removed dynamic designated array initialization. Use 16 byte alignment on arrays >= 16 for x64
This commit is contained in:
committed by
Christoffer Lerno
parent
26d25e3f74
commit
45c4f205bb
@@ -576,6 +576,11 @@ bool type_is_homogenous_aggregate(Type *type, Type **base, unsigned *elements)
|
||||
|
||||
AlignSize type_alloca_alignment(Type *type)
|
||||
{
|
||||
if (build_target.abi == ABI_X64)
|
||||
{
|
||||
type = type_flatten(type);
|
||||
if (type->type_kind == TYPE_ARRAY && type_size(type) >= 16) return 16;
|
||||
}
|
||||
return type_abi_alignment(type);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user