xref: /freebsd/lib/libc/amd64/stdlib/div.S (revision 2e3507c25e42292b45a5482e116d278f5515d04d)
1/*	$NetBSD: div.S,v 1.1 2001/06/19 00:25:04 fvdl Exp $	*/
2
3/*-
4 * Written by Frank van der Linden (fvdl@wasabisystems.com)
5 * Public domain.
6 */
7
8#include <machine/asm.h>
9ENTRY(div)
10	movl	%edi,%eax
11	cltd
12	idivl	%esi
13	salq	$32,%rdx
14	orq	%rdx,%rax
15	ret
16END(div)
17
18	.section .note.GNU-stack,"",%progbits
19