Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit 41cd45f

Browse files
livecodefraserlivecodeian
authored andcommitted
Patch the libffi source to fix an obsolete opcode
The libffi source uses the 'stmeqia' opcode. This is a compound opcode for the 'stm' (store multiple) instruction with two suffixes: 'eq' to indicate that it should only execute if the previous comparison result was equality and 'ia' to indicate the memory layout of the buffer. The canonical ordering of this suffixes is 'ia' then 'eq' (giving a final opcode of 'stmiaeq'). Libffi uses the other ordering, which GAS accepts but Clang's internal assembler does not. This change simply canonicalises the ordering of the suffixes allowing the code to compile with either tool.
1 parent fe2f67c commit 41cd45f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libffi/src/arm/sysv.S

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ LSYM(Lbase_args):
398398
beq LSYM(Lepilogue_vfp)
399399

400400
cmp r3, #FFI_TYPE_SINT64
401-
stmeqia r2, {r0, r1}
401+
stmiaeq r2, {r0, r1}
402402
beq LSYM(Lepilogue_vfp)
403403

404404
cmp r3, #FFI_TYPE_FLOAT

0 commit comments

Comments
 (0)