(C) 1998 AROS - The Amiga Research OS


NAME
#include <proto/utility.h>

ULONG UDivMod32 (dividend , divisor)

LOCATION
In UtilityBase at offset 26

SYNOPSIS
ULONG dividend
ULONG divisor

FUNCTION
Perform the 32 bit unsigned division and modulus of dividend by divisor, that is dividend / divisor. Will return both the quotient and the remainder.

INPUTS
dividend
The number to divide into (numerator).
divisor
The number to divide by (denominator).

RESULT
For m68k assembly programmers, D0: quotient D1: remainder

For HLL programmers, the quotient

EXAMPLE

SEE ALSO
SDivMod32(), SMult32(), SMult64(), UMult32(), UMult64()

NOTES
The utility.library math functions are unlike all other utility functions in that they don't require the library base to be loaded in register A6, and they also save the values of the address registers A0/A1.

This function is mainly to support assembly programers, and is probably of limited use to higher-level language programmers.

BUGS
It is impossible for C programmers to obtain the value of remainder.

INTERNALS
May actually be handled by code that is in config/$(KERNEL) This is the case for m68k-native.

HISTORY
20.10.1998 hkiel
Amiga Research OS
20.08.1997 digulla
Polish.

Renamed utility_intern.h to intern.h.

03.02.1997 ldp
Changed <proto/*_protos.h> to <proto/*.h>
02.02.1997 iaint
Some bug fixes, math functions and native Amiga support