home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / bsd_srcs / usr.bin / gcc / gnulib / longlong / ucmpdi2.c < prev    next >
Encoding:
C/C++ Source or Header  |  1991-01-21  |  396 b   |  21 lines

  1. #include "longlong.h"
  2.  
  3. SItype
  4. __ucmpdi2 (a, b)
  5.      long long a, b;
  6. {
  7.   long_long au, bu;
  8.  
  9.   au.ll = a, bu.ll = b;
  10.  
  11.   if ((unsigned) au.s.high < (unsigned) bu.s.high)
  12.     return 0;
  13.   else if ((unsigned) au.s.high > (unsigned) bu.s.high)
  14.     return 2;
  15.   if ((unsigned) au.s.low < (unsigned) bu.s.low)
  16.     return 0;
  17.   else if ((unsigned) au.s.low > (unsigned) bu.s.low)
  18.     return 2;
  19.   return 1;
  20. }
  21.