/* More subroutines needed by GCC output code on some machines. */1/* Compile this one with gcc. */2/* Copyright (C) 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,32000, 2001 Free Software Foundation, Inc.45This file is part of GNU CC.67GNU CC is free software; you can redistribute it and/or modify8it under the terms of the GNU General Public Licence as published by9the Free Software Foundation; either version 2, or (at your option)10any later version.1112In addition to the permissions in the GNU General Public Licence, the13Free Software Foundation gives you unlimited permission to link the14compiled version of this file into combinations with other programs,15and to distribute those combinations without any restriction coming16from the use of this file. (The General Public Licence restrictions17do apply in other respects; for example, they cover modification of18the file, and distribution when not linked into a combine19executable.)2021GNU CC is distributed in the hope that it will be useful,22but WITHOUT ANY WARRANTY; without even the implied warranty of23MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the24GNU General Public Licence for more details.2526You should have received a copy of the GNU General Public Licence27along with GNU CC; see the file COPYING. If not, write to28the Free Software Foundation, 59 Temple Place - Suite 330,29Boston, MA 02111-1307, USA. */3031/* It is incorrect to include config.h here, because this file is being32compiled for the target, and hence definitions concerning only the host33do not apply. */3435#include <linux/types.h>3637union DWunion {38s64 ll;39struct {40s32 low;41s32 high;42} s;43};4445s64 __negdi2(s64 u)46{47union DWunion w;48union DWunion uu;4950uu.ll = u;5152w.s.low = -uu.s.low;53w.s.high = -uu.s.high - ((u32) w.s.low > 0);5455return w.ll;56}575859