1285118Sjmmv/*- 2258299Sjmmv * Copyright (c) 1992, 1993 3258299Sjmmv * The Regents of the University of California. All rights reserved. 4258299Sjmmv * 5258299Sjmmv * This software was developed by the Computer Systems Engineering group 6258299Sjmmv * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and 7258299Sjmmv * contributed to Berkeley. 8258299Sjmmv * 9258299Sjmmv * Redistribution and use in source and binary forms, with or without 10258299Sjmmv * modification, are permitted provided that the following conditions 11258299Sjmmv * are met: 12258299Sjmmv * 1. Redistributions of source code must retain the above copyright 13258299Sjmmv * notice, this list of conditions and the following disclaimer. 14258299Sjmmv * 2. Redistributions in binary form must reproduce the above copyright 15258299Sjmmv * notice, this list of conditions and the following disclaimer in the 16258299Sjmmv * documentation and/or other materials provided with the distribution. 17258299Sjmmv * 4. Neither the name of the University nor the names of its contributors 18258299Sjmmv * may be used to endorse or promote products derived from this software 19258299Sjmmv * without specific prior written permission. 20258299Sjmmv * 21258299Sjmmv * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 22258299Sjmmv * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23258299Sjmmv * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24258299Sjmmv * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 25258299Sjmmv * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 26258299Sjmmv * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27258299Sjmmv * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28258299Sjmmv * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29258299Sjmmv * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30258299Sjmmv * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31258299Sjmmv * SUCH DAMAGE. 32258299Sjmmv */ 33258299Sjmmv 34258299Sjmmv#if defined(LIBC_SCCS) && !defined(lint) 35258299Sjmmvstatic char sccsid[] = "@(#)xordi3.c 8.1 (Berkeley) 6/4/93"; 36258299Sjmmv#endif /* LIBC_SCCS and not lint */ 37258299Sjmmv#include <sys/cdefs.h> 38258299Sjmmv__FBSDID("$FreeBSD$"); 39258299Sjmmv 40258299Sjmmv#include "quad.h" 41258299Sjmmv 42258299Sjmmv/* 43258299Sjmmv * Return a ^ b, in quad. 44258299Sjmmv */ 45258299Sjmmvquad_t 46258299Sjmmv__xordi3(a, b) 47258299Sjmmv quad_t a, b; 48258299Sjmmv{ 49258299Sjmmv union uu aa, bb; 50258299Sjmmv 51258299Sjmmv aa.q = a; 52258299Sjmmv bb.q = b; 53258299Sjmmv aa.ul[0] ^= bb.ul[0]; 54258299Sjmmv aa.ul[1] ^= bb.ul[1]; 55258299Sjmmv return (aa.q); 56258299Sjmmv} 57258299Sjmmv