This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Patch, fortran] PR25289 Cannot handle record numbers large than huge(0_4)
- From: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- To: FX Coudert <fxcoudert at gmail dot com>
- Cc: Jerry DeLisle <jvdelisle at verizon dot net>, gcc-patches <gcc-patches at gcc dot gnu dot org>, fortran at gcc dot gnu dot org
- Date: Wed, 28 Jun 2006 13:36:02 -0700
- Subject: Re: [Patch, fortran] PR25289 Cannot handle record numbers large than huge(0_4)
- References: <A7E4CB800B73A2409E113012513E03944CDFA8@EX1V.rl.gov> <44A20047.1010202@verizon.net> <44A21FD8.4090706@gmail.com>
On Wed, Jun 28, 2006 at 08:21:12AM +0200, FX Coudert wrote:
>
> I don't have time right now to review that patch. Here are my comments:
Jerry, I'm in the same boat with fx, but I should be able
to read through the code Saturday. Perhaps, we can get
in touch on IRC in the afternoon.
> >This patch
> >borrows code from trans-types.c to determine whether or not a target
> >supports integer 8 or not. A new function is added to make this
> >determination.
>
> I think we should use a constant to store that integer kind defined as
> "8 if integer(8) exists and 4 otherwise", to avoid calling a function
> each time we need it. We already have a constant gfc_max_integer_kind in
> place, we could either
>
> - use that gfc_max_integer_kind, because it is also known from the
> library, as GFC_INTEGER_LARGEST
>
> - use similar code than the one defining gfc_max_integer_kind to
> define gfc_large_integer_kind as "8 if possible, 4 otherwise"
>
You definitely don't want to use gfc_max_integer_kind. This
is integer*16 on most (if not all) 64 bit architectures. I
think we should go with the second option, but with a more
descriptive name, perhaps, gfc_record_integer_kind.
--
Steve