Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • sac2c sac2c
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 403
    • Issues 403
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • External wiki
    • External wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • sac-group
  • sac2csac2c
  • Issues
  • #1329
Closed
Open
Created Aug 04, 2004 by Kai Trojahner@ktrGuest

SSA renaming scheme is dangerous

Bugzilla Link 42
Created on Aug 04, 2004 17:19
Resolution FIXED
Resolved on Aug 05, 2004 23:15
Version 1.00beta
OS All
Architecture Sun
Attachments ssabug.sac

Extended Description

Multiple SSA transformations can lead to multiple declarations of variables due
to SSATransforms renaming scheme.
Take a look at the following example:
int[.], int[.] buggy( int[.] z) 
{
  unew = with (. <= iv <= .) 
         {
           zsum = 2 * z[iv];
         }
         genarray ([1024], zsum);
  unew = with ([0] <= iv <= [0])
         modarray (unew, iv, unew[[1023]]);
  vnew = with (. <= iv <= .)
         {
           zsum = 2 * z[iv];
         }
         genarray ([1024], zsum);
  return (unew, vnew);
}
As the syntaxtree is converted in and out of SSA form during WLEnhancement
(activated via -khf), zsum in the second with-loop is renamed into zsum__SSA1.
After UndoSSATransform in WLEnhancment, zsum__SSA1 is not re-renamed into zsum.
Now, with-loop folding folds the first two with-loops, yielding a new with-loop
with two generators whose results are both names zsum. The subsequent call of
RestoreSSAOneFunction will rename the second result into zsum__SSA1 which
already exists!
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking