This is the mail archive of the 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: [Patch] Factor self-referential size trees into functions

A nit: I don't like find_substitute_in_expr being in tree.c and I don't like its name.

Also, maybe you want the function to be named SZ.%d instead of SZ%d just for clarity in the gimple outputs with functions named SZ%d by the user (you never know -- though maybe Ada functions are mangled?)

  2. more aggressive propagation of TREE_READONLY in expressions.  Expressions
cannot be factored out if they contain SAVE_EXPRs so superfluous SAVE_EXPRs
must be eliminated as much as possible by tracking the TREE_READONLYness.

If I understand the patch correctly, this is a one-liner and could be submitted separately (personally, I would have no problem if the rest of the patch was approved by an Ada maintainer, or if you just went ahead and committed it).

This should only affect the Ada compiler (although I presume 2. can marginally
help the other compilers) and dramatically help for code with multiple levels
of discriminated types (for our favorite example at -O0: code size divided by
2 and compilation time by 4).

Roughly, what is the asymptotic complexity of multiple levels of discriminated types? Would this patch help with problems like the one you recently posted a patch for? (Just two curiosities).



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