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
  • #1094
Closed
Open
Created Sep 02, 2011 by Robert Bernecky@rbeDeveloper

TC can't simplify AKV _idxs2offset()

Bugzilla Link 868
Created on Sep 02, 2011 18:31
Version svn
OS Linux
Architecture PC

Extended Description

This isn't really a bug, inasmuch as it's 
desired new functionality for TC.
However, the CF unit test here:
cd ~/sac/testsuite/optimizations/constantfolding
UnitTestRunGrep1 SCCFprf_sel4ivecyc.sac
UnitTestRunGrep1 testing: SCCFprf_sel4ivecyc.sac
Greptest: SCCFprf_sel4ivecyc.sac -noewlcf -docf -doawlf failed with 3 hits on phrase "NESTEDSTRUCTCON". Wanted 0 hits
CF is unable to simplify the idx_sel() below, because 
_ivesplit_472 is not AKV, although it should be:
  _isaa_466_vec = 1;
  _ivesplit_473 = [ 3, 2 ];
  _iveras_475 = 0;
  _ivesplit_472 = _idxs2offset_( _ivesplit_473, _iveras_475, _isaa_466_vec);
  _icc_28 = _idx_sel_( _ivesplit_472, NESTEDSTRUCTCON);
sac2c -V
sac2c v1.00-beta (Haggis And Apple)
 developer rev 17585:MODIFIED linux-gnu_x86_64
 (Thu Sep  1 22:23:35 EDT 2011 by sac)
I looked at ct_prf.c, and it does contain code, likely
produced by yrs trly, for _idxs2offset. However, nowhere in
ct_prf.c is there anything I can find that actually evaluates
primitive expressions like "2+3", to produce an AKV result.
Ah, I am beginning to see a light, perhaps: It looks as if
there may be calls from TC to entries such as those
in constants_struc_ops.c, probably driven by the (also
undocumented) co_fun table entries in prf_info.mac.
Perhaps Mr. TC can either confirm this conjecture,
or provide the correct answer?
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking