1 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
2 /* All Rights Reserved */
6 * Copyright (c) 1980 Regents of the University of California.
7 * All rights reserved. The Berkeley software License Agreement
8 * specifies the terms and conditions for redistribution.
10 /* Portions Copyright(c) 1996, Sun Microsystems Inc. */
11 /* All Rights Reserved */
14 * Copyright (c) 1997, by Sun Microsystems, Inc.
15 * All rights reserved.
18 /* fix for bugid 1240660 redefine old libmp interfaces to go to the new */
19 /* mp_*() interfaces */
21 #ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
26 #include <sys/types.h>
29 void gcd(MINT
*a
, MINT
*b
, MINT
*c
) { mp_gcd(a
, b
, c
); }
31 void madd(MINT
*a
, MINT
*b
, MINT
*c
) { mp_madd(a
, b
, c
); }
33 void msub(MINT
*a
, MINT
*b
, MINT
*c
) { mp_msub(a
, b
, c
); }
35 void mdiv(MINT
*a
, MINT
*b
, MINT
*q
, MINT
*r
) { mp_mdiv(a
, b
, q
, r
); }
37 void sdiv(MINT
*a
, short n
, MINT
*q
, short *r
) { mp_sdiv(a
, n
, q
, r
); }
39 int min(MINT
*a
) { return (mp_min(a
)); }
41 void mout(MINT
*a
) { mp_mout(a
); }
43 int msqrt(MINT
*a
, MINT
*b
, MINT
*r
) { return (mp_msqrt(a
, b
, r
)); }
45 void mult(MINT
*a
, MINT
*b
, MINT
*c
) { mp_mult(a
, b
, c
); }
47 void pow(MINT
*a
, MINT
*b
, MINT
*c
, MINT
*d
) { mp_pow(a
, b
, c
, d
); }
49 void rpow(MINT
*a
, short n
, MINT
*b
) { mp_rpow(a
, n
, b
); }
51 MINT
*itom(short n
) { return (mp_itom(n
)); }
53 int mcmp(MINT
*a
, MINT
*b
) { return (mp_mcmp(a
, b
)); }
55 MINT
*xtom(char *key
) { return (mp_xtom(key
)); }
57 char *mtox(MINT
*key
) { return (mp_mtox(key
)); }
59 void mfree(MINT
*a
) { mp_mfree(a
); }
62 short *xalloc(int nint
, char *s
) { return (_mp_xalloc(nint
, s
)); }
64 void xfree(MINT
*c
) { _mp_xfree(c
); }