This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
How can a front-end know what integer mode corresponds to int_fastN_t?
- From: FX Coudert <fxcoudert at gmail dot com>
- To: "fortran at gcc dot gnu dot org List" <fortran at gcc dot gnu dot org>, GCC Development <gcc at gcc dot gnu dot org>
- Date: Mon, 16 Oct 2006 23:27:51 +0200
- Subject: How can a front-end know what integer mode corresponds to int_fastN_t?
Hi all,
For Fortran 2003 standard conformance, the Fortran front-end has to
know at compile-time what integer mode corresponds to some C99 types,
like intmax_t, intN_t, int_leastN_t, int_fastN_t.
For intN_t and int_leastN_t, I can see how to get them by looking at
the width of the different integer modes. For intmax_t, it is defined
in c-common.h as:
#define INTMAX_TYPE ((INT_TYPE_SIZE == LONG_LONG_TYPE_SIZE) \
? "int" \
: ((LONG_TYPE_SIZE == LONG_LONG_TYPE_SIZE) \
? "long int" \
: "long long int"))
But I cannot see how the front-end can know the integer mode for
int_leastN_t. We're likely to include this functionality for the 4.3
release, so I'll be happy to get a large number of suggestions around
on how to implement that.
FX