Eliminating SSA variables

"Richard M." <richard@imagecraft.com>
28 Jul 2005 02:31:17 -0400

          From comp.compilers

Related articles
Eliminating SSA variables richard@imagecraft.com (Richard M.) (2005-07-28)
Re: Eliminating SSA variables jsinger@cs.man.ac.uk (Jeremy Singer) (2005-07-31)
Re: Eliminating SSA variables drizzle76@gmail.com (dz) (2005-07-31)
Re: Eliminating SSA variables ali@olympe.ch (Ali Al-Shabibi) (2005-07-31)
| List of all articles for this month |
From: "Richard M." <richard@imagecraft.com>
Newsgroups: comp.compilers
Date: 28 Jul 2005 02:31:17 -0400
Organization: ImageCraft Creations Inc.
Keywords: analysis, question, SSA
Posted-Date: 28 Jul 2005 02:31:17 EDT

Given a source program fragment like this:
int i;
for (i = 0; i < 10; i++)
        ;


After SSA transformation and back, we have


i = 0;
i1 = i;
top:
      i2 = i1+1;
      i1 = i2;
if (i2 < 10) goto top;
...


The problem now is that there are 2 variables inside the loop, i1 and i2
with overlapping lifetimes, thus using more registers and causing extra
register moves at code generation time. Is there something we can do to
address this problem?


Thanks for any hints and pointers!


--
// richard
http://www.imagecraft.com


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.