[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Schedule for GNU make 3.81
From: |
Eli Zaretskii |
Subject: |
Re: Schedule for GNU make 3.81 |
Date: |
Sun, 20 Feb 2005 22:09:44 +0200 |
> Date: Wed, 16 Feb 2005 01:45:41 -0500
> From: address@hidden
>
> http://make.paulandlesley.org/make-3.81beta2.tar.bz2
> http://make.paulandlesley.org/make-3.81beta2.tar.gz
Here's an annoyance with this beta version when I build it with DJGPP
and GCC 3.3.3 or 3.4.3:
gcc -I. -I. -I. -I./glob -DLIBDIR=\"c:/djgpp/lib\"
-DINCLUDEDIR=\"c:/djgpp/include\" -DLOCALEDIR=\"/share/locale\" -DHAVE_CONFIG_H
-O2 -g -c file.c
file.c: In function `file_timestamp_cons':
file.c:554: warning: comparison is always true due to limited range of data
type
The macro-expanded version of the function file_timestamp_cons is
below. The expression that triggers the warning seems to be the first
line of the `if' clause, viz.:
if (! (s <= (((((((((~ (unsigned long long) 0 - (! ((unsigned long long) -1 <
0) ? (unsigned long long) 0 : ~ (unsigned long long) 0 << (sizeof (unsigned
long long) * 8 - 1)))) - (2 + 1)) >> (0 ? 30 : 0)) << (0 ? 30 : 0)) + (2 + 1) +
(0 ? 1000000000 : 1) - 1)) - (2 + 1)) >> (0 ? 30 : 0))
I might be wrong, but I think that the offending comparison is this:
(unsigned long long) -1 < 0
which comes from this line in make.h:
#define INTEGER_TYPE_SIGNED(t) ((t) -1 < 0)
I tried a few tricks to avoid the warning, but was unable to shut it
up. Can someone see what's wrong and how to fix that?
----------------------------------------------------------------------
unsigned long long
file_timestamp_cons (const char *fname, time_t s, int ns)
{
int offset = (2 + 1) + (0 ? ns : 0);
unsigned long long product = (unsigned long long) s << (0 ? 30 : 0);
unsigned long long ts = product + offset;
if (! (s <= (((((((((~ (unsigned long long) 0 - (! ((unsigned long long) -1 <
0) ? (unsigned long long) 0 : ~ (unsigned long long) 0 << (sizeof (unsigned
long long) * 8 - 1)))) - (2 + 1)) >> (0 ? 30 : 0)) << (0 ? 30 : 0)) + (2 + 1) +
(0 ? 1000000000 : 1) - 1)) - (2 + 1)) >> (0 ? 30 : 0))
&& product <= ts && ts <= ((((((~ (unsigned long long) 0 - (!
((unsigned long long) -1 < 0) ? (unsigned long long) 0 : ~ (unsigned long long)
0 << (sizeof (unsigned long long) * 8 - 1)))) - (2 + 1)) >> (0 ? 30 : 0)) << (0
? 30 : 0)) + (2 + 1) + (0 ? 1000000000 : 1) - 1)))
{
char buf[(((sizeof (unsigned long long) * 8 - 1 - 24) * 302 / 1000) + 1 +
1 + 4 + 25) + 1];
ts = s <= 2 ? (2 + 1) : ((((((~ (unsigned long long) 0 - (! ((unsigned
long long) -1 < 0) ? (unsigned long long) 0 : ~ (unsigned long long) 0 <<
(sizeof (unsigned long long) * 8 - 1)))) - (2 + 1)) >> (0 ? 30 : 0)) << (0 ? 30
: 0)) + (2 + 1) + (0 ? 1000000000 : 1) - 1);
file_timestamp_sprintf (buf, ts);
error (((struct floc *)0), ((const char *) ("%s: Timestamp out of range;
substituting %s")),
fname ? fname : ((const char *) ("Current time")), buf);
}
return ts;
}
- Schedule for GNU make 3.81, psmith, 2005/02/16
- Re: Schedule for GNU make 3.81, Andreas M. Kirchwitz, 2005/02/16
- Re: Schedule for GNU make 3.81, Marty Leisner, 2005/02/16
- I: [PATCH] make-3.81beta2 func_shell segfault fix, Dmitry V. Levin, 2005/02/17
- Re: Schedule for GNU make 3.81, Eli Zaretskii, 2005/02/19
- Re: Schedule for GNU make 3.81, J. Grant, 2005/02/19
- Re: Schedule for GNU make 3.81,
Eli Zaretskii <=