1/*
2 * Written by J.T. Conklin <jtc@netbsd.org>.
3 * Public domain.
4 */
5
6#include <machine/asm.h>
7__FBSDID("$FreeBSD: head/lib/libc/i386/stdlib/div.S 108151 2002-12-21 05:11:39Z tjr $");
8
9ENTRY(div)
10 pushl %ebx
11 movl 8(%esp),%ebx
12 movl 12(%esp),%eax
13 movl 16(%esp),%ecx
14 cdq
15 idiv %ecx
16 movl %eax,(%ebx)
17 movl %edx,4(%ebx)
18 popl %ebx
19 ret $4
2 * Written by J.T. Conklin <jtc@netbsd.org>.
3 * Public domain.
4 */
5
6#include <machine/asm.h>
7__FBSDID("$FreeBSD: head/lib/libc/i386/stdlib/div.S 108151 2002-12-21 05:11:39Z tjr $");
8
9ENTRY(div)
10 pushl %ebx
11 movl 8(%esp),%ebx
12 movl 12(%esp),%eax
13 movl 16(%esp),%ecx
14 cdq
15 idiv %ecx
16 movl %eax,(%ebx)
17 movl %edx,4(%ebx)
18 popl %ebx
19 ret $4