Align on 4n bytes when copying fct args on stack
When copying function arguments on stack in prolog, use multiple of 4 bytes for alignment.
This commit is contained in:
parent
e0aee4f455
commit
6c4d3244da
1 changed files with 1 additions and 0 deletions
|
|
@ -1202,6 +1202,7 @@ void gfunc_prolog(CType *func_type)
|
||||||
type = &sym->type;
|
type = &sym->type;
|
||||||
size = type_size(type, &align);
|
size = type_size(type, &align);
|
||||||
size = (size + 3) >> 2;
|
size = (size + 3) >> 2;
|
||||||
|
align = (align + 3) & ~3;
|
||||||
#ifdef TCC_ARM_HARDFLOAT
|
#ifdef TCC_ARM_HARDFLOAT
|
||||||
if (!variadic && (is_float(sym->type.t)
|
if (!variadic && (is_float(sym->type.t)
|
||||||
|| is_float_hgen_aggr(&sym->type))) {
|
|| is_float_hgen_aggr(&sym->type))) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue