Mandriva's Arnaud Patard proposed the following function body to me on IRC:
@
@ Written by Peter Naulls <email address hidden>
@ Modified by Caolan McNamara <email address hidden>
.file "armhelper.s"
.text
.align 4
.global privateSnippetExecutor
.type privateSnippetExecutor, %function
privateSnippetExecutor:
.fnstart
stmfd sp!, {r0-r3, lr } @ follow other parameters on stack
.save {r0-r3, lr}
mov r0, ip @ r0 points to functionoffset/vtable
mov r1, sp @ r1 points to this and params
bl cpp_vtable_call(PLT)
ldmfd sp!, {r0-r3, lr}
bx lr
.fnend
Mandriva's Arnaud Patard proposed the following function body to me on IRC: xecutor xecutor, %function xecutor: vtable call(PLT)
@
@ Written by Peter Naulls <email address hidden>
@ Modified by Caolan McNamara <email address hidden>
.file "armhelper.s"
.text
.align 4
.global privateSnippetE
.type privateSnippetE
privateSnippetE
.fnstart
stmfd sp!, {r0-r3, lr } @ follow other parameters on stack
.save {r0-r3, lr}
mov r0, ip @ r0 points to functionoffset/
mov r1, sp @ r1 points to this and params
bl cpp_vtable_
ldmfd sp!, {r0-r3, lr}
bx lr
.fnend
http:// pastebin. mandriva. com/17521