freebsd-dev/lib/libc/i386/stdlib/div.S

20 lines
274 B
ArmAsm
Raw Normal View History

/*
* Written by J.T. Conklin <jtc@netbsd.org>.
* Public domain.
*/
#include <machine/asm.h>
2002-03-23 02:44:19 +00:00
__FBSDID("$FreeBSD$");
ENTRY(div)
pushl %ebx
movl 8(%esp),%ebx
movl 12(%esp),%eax
movl 16(%esp),%ecx
cdq
idiv %ecx
movl %eax,(%ebx)
movl %edx,4(%ebx)
popl %ebx
ret $4