This is the mail archive of the gcc-patches@gcc.gnu.org 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 0/9: IRA cleanups and preparations for tracking subwords of DImode


On 06/18/2010 09:59 AM, Bernd Schmidt wrote:
I will post a series of patches as a followups to this message; the goal
of it is to eventually enable us to accurately track lifetimes of
subwords of DImode values in IRA.  For an example, see PR42502.  That
testcase has one remaining problem: we generate unnecessary moves, since
IRA thinks a hard reg conflicts with a DImode value when in fact it only
conflicts with one subword.

The problem goes back to
   http://gcc.gnu.org/ml/gcc-patches/2008-04/msg01990.html
where Kenneth removed REG_NO_CONFLICT blocks, acknowledging that this
would cause codegen regressions, but without providing any kind of
replacement for the functionality other than a promise that Vlad would
fix it in IRA.  IMO that should never have been approved, but we'd
probably have lost the functionality with the conversion to IRA anyway.

The idea behind these patches is to create a new ira_object structure
which tracks live ranges and conflicts.  In a first step, there is one
such object per allocno; the final patch will add two of them for
suitable multiword allocnos.

This patch queue is unfinished for now: the final piece, which adds
ALLOCNO_NUM_OBJECTS and the possiblity of having more than one object
per allocno, seems to be working, but I haven't tested it very much yet
and I don't think I'll get it sufficiently cleaned up before the
weekend.  So I'm posting the patches that are already done for initial
review now.

I think the initial few cleanup patches should go in in any case so I'm
asking for approval for them.  The final three patches in this
submission perform the conversion to use ira_objects and probably don't
qualify on their own, but neither do they have any significant negative
impact - only a few additional ALLOCNO_OBJECT/OBJECT_ALLOCNO
conversions.  It would be good to know if there are any objections in
principle against the approach.

Thanks for addressing the problem, Bernd.

Personally I have no principle objections to the approach. I am only not sure that it will help benchmarks a lot (after Ian introduced lowering subreg pass although it is a bit conservative) and I am a bit afraid that it makes IRA even more complicated. But in any case we should try this patch may be it will work very well and will be not so complicated as Ken's one.

None of these preliminary patches have been observed to change code
generation in any way.  With the whole set applied I've bootstrapped and
regression tested on i686-linux.

Bernd, I'll be on vacation next week and could start to review all patches then if Jeff does not approve them when I am back.

As for patches already approved by Jeff. They are ok to me too.


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