[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time val
From: |
Eli Zaretskii |
Subject: |
Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes |
Date: |
Sat, 03 Jan 2009 17:33:20 +0200 |
> Date: Sat, 3 Jan 2009 14:53:25 +0100
> From: "Juanma Barranquero" <address@hidden>
> Cc: address@hidden
>
> On Sat, Jan 3, 2009 at 14:28, Juanma Barranquero <address@hidden> wrote:
>
> >> Could you please show the values of ft_kernel, stime_sec, and
> >> stime_usec after the last of the above 3 lines, namely after
> >>
> >> stime_sec = tem1 * 0.000001L;
> >>
> >> ?
>
> Hmm.
>
> The inlined code that implements the fmodl() call seems to be modifying tem1;
> doing
>
> snprintf (buf, sizeof (buf), "tem1 (1) = %Lf\n", tem1);
> OutputDebugString (buf);
> stime_usec = fmodl (tem1, 1000000.0L);
> snprintf (buf, sizeof (buf), "tem1 (2) = %Lf\n", tem1);
> OutputDebugString (buf);
>
> I get the following results:
>
> tem1 (1) = 82703125.000000
> tem1 (2) = 703125.000000
That's a bug in GCC, I'd say: all these variables are in registers, so
it probably reuses one of the FP registers incorrectly.
What happens if you transpose these two lines:
stime_usec = fmodl (tem1, 1000000.0L);
stime_sec = tem1 * 0.000001L;
(and similarly for other ?time_* qualities)? does the code work again
then? (Note that I reuse tem1 and tem2 twice in the code, so even if
transposition works, something else will need to be done to make all
of the function work correctly.)
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, (continued)
Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/01
Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Eli Zaretskii, 2009/01/01
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/02
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Eli Zaretskii, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes,
Eli Zaretskii <=
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Eli Zaretskii, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Eli Zaretskii, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Eli Zaretskii, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Jason Rumney, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Jason Rumney, 2009/01/03
- Re: Optimized gcc 4.3.0 build on Windows returns 0 secs for all time values of system-process-attributes, Juanma Barranquero, 2009/01/03