fixes for host gcc 4.6.1
[zpugcc/jano.git] / toolchain / gcc / newlib / libc / machine / w65 / cmpsi.c
blob3773c9d2e90a3212d4f3842ce94cd232d9e4341c
2 union u {
3 struct {
4 short int msw;
5 unsigned short lsw;
6 } w;
7 long l;
8 };
10 int
11 __cmpsi2(long arga,
12 short int msw_b, unsigned short int lsw_b)
14 union u u;
15 u.l = arga;
17 if (u.w.msw != msw_b)
19 if (u.w.msw < msw_b) return 0;
20 return 2;
22 if (u.w.lsw != lsw_b)
24 if (u.w.lsw < lsw_b) return 0;
25 return 2;
27 return 1;