This is the mail archive of the
mailing list for the GCC project.
Re: Patch for gcc.c-torture/execute/ieee/20010226-1.c
- From: Fergus Henderson <fjh at cs dot mu dot OZ dot AU>
- To: "D.Venkatasubramanian, Noida" <dvenkat at noida dot hcltech dot com>
- Cc: gcc-patches at gcc dot gnu dot org, "'gcc at gcc dot gnu dot org'" <gcc at gcc dot gnu dot org>
- Date: Mon, 23 Sep 2002 21:42:33 +1000
- Subject: Re: Patch for gcc.c-torture/execute/ieee/20010226-1.c
- References: <E04CF3F88ACBD5119EFE00508BBB21210489C11C@exch-01.noida.hcltech.com>
On 23-Sep-2002, D.Venkatasubramanian, Noida <email@example.com> wrote:
> I found the test case gcc.c-torture/execute/ieee/20010226-1.c failing on the
> h8300-elf target. On investigation, it was found that the test case expects
> the sizeof(long double) to have more than 4 bytes. On targets such as
> h8300-elf, the test case would thus fail.
> I am submitting a patch, which would prevent the test case from failing for
> targets where long double sizes are deficient.
> Is it okay?
> + /* Some targets may not support double precision floating point
> + * this test case should pass for such targets. */
> + if (sizeof(long double) <= 4)
> + exit (0);
You are assuming 8-bit bytes here.
Consider a system in which char, short, int, long, and long double are
all 64 bits. Then sizeof(long double) = 1. But ideally we wouldn't
want to disable this test on such a system, would we?
Fergus Henderson <firstname.lastname@example.org> | "I have always known that the pursuit
The University of Melbourne | of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.