[PATCH, fortran] PR20441 -finit-local-zero

Tobias Schlüter tobias.schlueter@physik.uni-muenchen.de
Tue Aug 21 17:23:00 GMT 2007


François-Xavier Coudert wrote:
>>> PS: I wonder whether it makes sense to have -finit-character=c to
>>> initially character variables with, e.g. "XXXXXXXXXXXXXXXXXXXX".
>> It makes sense, but I left it out because I didn't know if anyone
>> would find it useful.  I can easily add an finit-character option,
>> though.
> 
> I'd find it useful. I think -finit-character=32 would fill with
> spaces, and so on (ie, using a ASCII value as argument).

I'm wondering if all these options are really useful enough to justify 
their existence.  What additional benefit does this fine-grained control 
have over, say, one option that allows me to give a 32bit value that 
will be filled into any variable's space?  This suggestions allows 
behavior for -finit-local-zero, and therefore fixes the backwards 
ocmpatibility issue.  For debugging, I don't think there's a realistic 
case where this is not sufficient.

I'm somewhat doubtful that the maintenance overhead is worth the general 
solution.  We have already identified two cases previously not thought 
of in this thread.  Another issue that has remained unadressed so far: 
what happens if I initialize a INTEGER*1 to 2**20?  I'm sure I could 
think of more issues or potential headaches.

Cheers,
- Tobi



More information about the Fortran mailing list