Discussion:
[patch, fortran] Fux PR 87782
Thomas Koenig
2018-11-01 19:13:27 UTC
Permalink
Hello world,

the attached patch fixes the PR by not trying to determine the length
of the base symbol when there is a substring with a length which
is not constant. This might make the length of temporary strings
generated by the front end optimization pass shorter, while inserting
an additional call to determine length of the substring.

No test case because the failure was only exposed by an instrumented
compiler.

Regression-tested. OK for trunk?

Regards

Thomas

2018-11-01 Thomas Koenig <***@gcc.gnu.org>

PR fortran/87782
* frontend-passes.c (constant_string_length): If there is a
substring with a length which cannot be reduced to a constant,
return NULL.
Janne Blomqvist
2018-11-01 19:20:45 UTC
Permalink
Post by Thomas Koenig
Hello world,
the attached patch fixes the PR by not trying to determine the length
of the base symbol when there is a substring with a length which
is not constant. This might make the length of temporary strings
generated by the front end optimization pass shorter, while inserting
an additional call to determine length of the substring.
No test case because the failure was only exposed by an instrumented
compiler.
Regression-tested. OK for trunk?
Ok, thanks!
--
Janne Blomqvist
Loading...