This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: wide-int, fortran



Hi,

On 2013-11-24 22:38, N.M. Maclaren wrote:
The main problem is that integer constant expressions in C are limited to
the built-in operators, of which the only tricky ones are division and
remainder (and, occasionally, multiplication) - see C11 6.6#3.  Fortran
is not so limited, and there are much wider requirements for expression
evaluation at compile time.

please note that the standard-mandated compile-time evaluation is handled almost [*] entirely inside the Fortran frontend, viz. arith.c, resolve.c, simplify.c, intrinsic.c, maybe others, whereas the wide-int changes deal with the middle-end interface and touches none of these files.

Cheers,
- Tobi

[*] TRANSFER the a special case because it needs to know memory layouts

But at both ends of the compiler there are still limits.

And my point is that this is NOT an area that separates cleanly into
front and back end!

However, from your description, this is one component of any solution
for gfortran, and it doesn't sound as if it will cause trouble until
and unless someone wants to extend gfortran to wider types.  They will
then have to implement the other components ....


Regards,
Nick Maclaren.





Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]