xref: /csrg-svn/lib/libc/quad/notdi2.c (revision 61160)
153443Sbostic /*-
2*61160Sbostic  * Copyright (c) 1992, 1993
3*61160Sbostic  *	The Regents of the University of California.  All rights reserved.
453443Sbostic  *
553794Sbostic  * This software was developed by the Computer Systems Engineering group
653794Sbostic  * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and
753794Sbostic  * contributed to Berkeley.
853794Sbostic  *
953443Sbostic  * %sccs.include.redist.c%
1053443Sbostic  */
1153443Sbostic 
1253443Sbostic #if defined(LIBC_SCCS) && !defined(lint)
13*61160Sbostic static char sccsid[] = "@(#)notdi2.c	8.1 (Berkeley) 06/04/93";
1453443Sbostic #endif /* LIBC_SCCS and not lint */
1553443Sbostic 
1653794Sbostic #include "quad.h"
1753459Sbostic 
1853794Sbostic /*
1953794Sbostic  * Return ~a.  For some reason gcc calls this `one's complement' rather
2053794Sbostic  * than `not'.
2153794Sbostic  */
2254431Sbostic quad_t
__one_cmpldi2(a)2354431Sbostic __one_cmpldi2(a)
2454431Sbostic 	quad_t a;
2553443Sbostic {
2653794Sbostic 	union uu aa;
2753443Sbostic 
2853794Sbostic 	aa.q = a;
2953794Sbostic 	aa.ul[0] = ~aa.ul[0];
3053794Sbostic 	aa.ul[1] = ~aa.ul[1];
3153794Sbostic 	return (aa.q);
3253443Sbostic }
33