11849Swollman/*
2108176Skan * Copyright (c) 1993 Winning Strategies, Inc.
3108176Skan * All rights reserved.
4108176Skan *
5108176Skan * Redistribution and use in source and binary forms, with or without
6108176Skan * modification, are permitted provided that the following conditions
7108176Skan * are met:
8108176Skan * 1. Redistributions of source code must retain the above copyright
9108176Skan *    notice, this list of conditions and the following disclaimer.
10108176Skan * 2. Redistributions in binary form must reproduce the above copyright
11108176Skan *    notice, this list of conditions and the following disclaimer in the
12108176Skan *    documentation and/or other materials provided with the distribution.
13108176Skan * 4. The name of the author may not be used to endorse or promote products
14108176Skan *    derived from this software without specific prior written permission
15108176Skan *
16108176Skan * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
17108176Skan * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18108176Skan * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
19108176Skan * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
20108176Skan * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
21108176Skan * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22108176Skan * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23108176Skan * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24108176Skan * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25108176Skan * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
261849Swollman */
271849Swollman
2885437Speter#include <machine/asm.h>
2993000Sobrien__FBSDID("$FreeBSD$");
301849Swollman
311849SwollmanENTRY(div)
32108176Skan        movl    4(%esp),%eax
33108176Skan        movl    8(%esp),%ecx
34108176Skan        cdq
35108176Skan        idiv    %ecx
36108176Skan        ret
37184548SpeterEND(div)
38217106Skib
39217106Skib	.section .note.GNU-stack,"",%progbits
40