This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Question on scalar replacement
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- To: dnovillo at redhat dot com
- Cc: gcc at gcc dot gnu dot org
- Date: Sun, 13 Jun 04 19:02:47 EDT
- Subject: Re: Question on scalar replacement
Test case?
See the first line of the message. It's a-colire.adb in the Ada library.
But the problem is that it needs some changes that I haven't checked in
yet (and can't since they aren't working).
It's as if the main loop in scalarize structures didn't nfind
any virtual operands on that store. Does -fdump-tree-sra-vops show
virtual operands in that statement? There should be a V_MAY_DEF to
FRAME.64.
# T.47_89 = PHI <T.47_31(4), T.47_35(23)>;
# TMT.193_8 = PHI <TMT.193_93(4), TMT.193_86(23)>;
# TMT.192_1 = PHI <TMT.192_91(4), TMT.192_87(23)>;
# FRAME.64_85 = PHI <FRAME.64_32(4), FRAME.64_33(23)>;
# j_6 = PHI <j_106(4), j_107(23)>;
<L10>:;
# TMT.192_94 = V_MAY_DEF <TMT.192_1>;
# TMT.193_95 = V_MAY_DEF <TMT.193_8>;
# FRAME.64_33 = V_MAY_DEF <FRAME.64_85>;
FRAME.64.M12b = system__secondary_stack__ss_mark ();
j.46_34 = (ada__command_line__remove__remove_argument__2__L_3__T9b___XDL_1)j_6;
# TMT.192_96 = V_MAY_DEF <TMT.192_94>;
# TMT.193_97 = V_MAY_DEF <TMT.193_95>;
# T.47_35 = V_MAY_DEF <T.47_89>;
T.47 = ada__command_line__argument (j.46_34);
> There is no documenation in the front of tree-sra.c
Every function is documented.
Right, but what I meant is that the comments in the head of the file that
gives an overview of the algorithm and methodology of the file.
And I thought that my repeated calls for documentation review had been
answered.
As did I. There was a discussion on the GCC list about the documentation
standards, which I heavily participated in, which set standards that
everybody agreed on. The most important part of those standards were
that there be file-level overviews of each file. Since everybody agreed
this was a requirement, I didn't feel the need to personally verify
that it had been done. Shortly before the merge, I did send email asking
if all the required documentation was done and was told it was. Again,
I didn't see any need to personally review it.
If you let me know what you find difficult to understand in
tree-sra.c, I'll happily add more explanations to the code.
There's simply *no* documentation at the start of the file at all containing
any overview. It's not a matter of documentation being "easy" or "hard"
to understand: it's not there at all!
Once it's there, I'll be more than happy to comment on the difficulty
in understanding it.
The point is that just like you shouldn't have to look inside the code
of a function to figure out what it does and how to call it, you
shouldn't have to look past the beginning of a file to know what that
file does (in the case of optimizations, what the transformation looks
like) and how it does it (in general terms, of course).
I would never start looking at the documentation of individual
functions until I clearly understood the file-level documentation.