I notice that when the /check:bounds flag is set the program size increases dramatically (from 9 MB to 22 MB). What can be done to lessen this?
If you have a lot of array references and multidimensional arrays, that's a lot of checking code, plus inhibited optimizations (assuming enabled) due to branches and more intermediate language. What problem does this cause for you?
Thanks for the quick response! The main issue I am encountering is having to justify to QA why the program size is changing when migrating programs from CVF.
I tested an old Compaq Visual Compiler 6.5 install and the switch to enable array abounds and it only increased it by 30% not 300% like IVF. The new messages are more specific and useful, but at the cost of program size.
CVF 6.5: forrtl: severe (161): Program Exception - array bounds exceeded
IVF 16.0: forrtl: severe (408): fort: (2): Subscript #2 of the array SPAN has value 102 which is greater than the upper bound of 101
Opening up the IVF generated EXE in a text editor I see format statements like: "fort: (%d): Dummy character variable '%s' has length %ld which is greater than actual variable length %ld" repeated thousands of times. Is this expected? Is there a way to reduce the impact?
Escalated as issue DPD200414349. To my mind, this text doesn't belong in the generated code at all. We have a message catalog used for run-time errors (that also gets translated to Japanese.) Thanks for bringing this to our attention.
It turns out I was mistaken when I thought I had reproduced the problem - I didn't notice that we generate two message templates that have different wording. These are created only once per program unit.
If you have a test case that shows more than one set of texts per program unit (subroutine, function, etc.) please attach it. Otherwise I would suggest that the difference lies elsewhere.