diff options
author | Ash Wolf <ninji@wuffs.org> | 2022-11-07 03:06:21 +0000 |
---|---|---|
committer | Ash Wolf <ninji@wuffs.org> | 2022-11-07 03:06:21 +0000 |
commit | 9a46dd0e2e80790d9848c0bbd718932a27c23269 (patch) | |
tree | e7a8e976c7138d50a69ff4778c4e8572efd94452 /compiler_and_linker/unsorted/CMachine.c | |
parent | d0b9848c54e6f85ab713f059dcd1ddef7e57caa6 (diff) | |
download | MWCC-9a46dd0e2e80790d9848c0bbd718932a27c23269.tar.gz MWCC-9a46dd0e2e80790d9848c0bbd718932a27c23269.zip |
honk
Diffstat (limited to 'compiler_and_linker/unsorted/CMachine.c')
-rw-r--r-- | compiler_and_linker/unsorted/CMachine.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/compiler_and_linker/unsorted/CMachine.c b/compiler_and_linker/unsorted/CMachine.c index f34ec88..fd4aafc 100644 --- a/compiler_and_linker/unsorted/CMachine.c +++ b/compiler_and_linker/unsorted/CMachine.c @@ -186,6 +186,7 @@ SInt32 CMach_ArgumentAlignment(Type *type) { return align; } +// TODO: investigate if this returns SInt16 actually SInt32 CMach_AllocationAlignment(Type *type, UInt32 qual) { SInt32 align; SInt32 qualalign; @@ -573,7 +574,7 @@ void CMach_InitIntMem(Type *type, CInt64 val, void *mem) { } } -void CMach_InitVectorMem(Type *type, MWVector128 val, void *mem) { +void CMach_InitVectorMem(Type *type, MWVector128 val, void *mem, Boolean flag) { unsigned char uc[16]; unsigned short us[8]; unsigned int ul[4]; @@ -856,7 +857,7 @@ static SInt16 CMach_GetQualifiedStructAlign(TypeStruct *tstruct, Boolean flag) { switch (copts.align_mode) { case AlignMode3_1Byte: - case AlignMode8: + case AlignMode8_Packed: return 1; case AlignMode0_Mac68k: return 2; @@ -941,7 +942,7 @@ static SInt16 CMach_GetQualifiedClassAlign(TypeClass *tclass, Boolean flag) { switch (copts.align_mode) { case AlignMode3_1Byte: - case AlignMode8: + case AlignMode8_Packed: return 1; case AlignMode0_Mac68k: return 2; @@ -1047,7 +1048,7 @@ static SInt16 CMach_GetQualifiedTypeAlign(Type *type, Boolean flag) { switch (copts.align_mode) { case AlignMode3_1Byte: - case AlignMode8: + case AlignMode8_Packed: return 1; case AlignMode4_2Byte: case AlignMode5_4Byte: @@ -1166,7 +1167,7 @@ static SInt16 CMach_GetMemberAlignment(Type *type, SInt32 var, Boolean flag) { align = 16; switch (copts.align_mode) { - case AlignMode8: + case AlignMode8_Packed: align = 1; break; case AlignMode0_Mac68k: @@ -1266,7 +1267,7 @@ SInt32 CMach_StructLayoutBitfield(TypeBitfield *tbitfield, UInt32 qual) { switch (copts.align_mode) { case AlignMode3_1Byte: - case AlignMode8: + case AlignMode8_Packed: required_alignment = 0; break; } |