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
  • #1265
Closed
Open
Created Jun 01, 2012 by Robert Bernecky@rbeDeveloper

PM not skipping guard when asked to, in

Bugzilla Link 964
Created on Jun 01, 2012 21:34
Version svn
OS Linux
Architecture PC

Extended Description

I have this code, and I want PM to get me to _pinl_2005_idc_1362:
 _pinl_2005__idc_1362 = [ _flat_27, _uprf_2801 ];
...
  _pinl_2007__idc_1363, _pinl_2006__icc_1360_pred = _prod_matches_prod_shape_VxA_( _pinl_2005__idc_1362, _pinl_2008__icc_1447);
Here is the pattern used by IVUTisShapesMatch:
   pat1 = PMvar( 1, PMAgetNode( &shp), 0);
   pat2 = PMvar( 1, PMAisNode( &shp), 0);
   z = ( PMmatchFlatSkipExtremaAndGuards( pat1, AVIS_SHAPE( pavis)) &&
         PMmatchFlatSkipExtremaAndGuards( pat2, AVIS_SHAPE( cavis)));
AVIS_SHAPE( pavis) points to _pinl_2007__idc_1363.
I expected that the search should skip the guard, and then stop.
However, I set breakpoints at PMMisInGuards, and we never
stop there. Which seems odd to me. 
The code in pattern_match_modes.c has a plausible look to it. 
Ergo, I are confused.
Compiled on Build #17858 with these options:
  sac2c -v1 crud.sac -doawlf -nowlf -bopt:uglf >crud
Here is the offending crud.sac:
use Array:{+,-,sum,prod,toi,genarray,<,iota};
inline int[*] rhoIII(int[.] x, int y)
{ /* Vector reshape scalar to matrix) */
  zxrho = prod(toi(x)); /* Result element count */
  z = genarray([zxrho], y); /* allocate result */
  z = _reshape_VxA_(toi(x),z);
  return(z);
}
int[*] id( int[*] y)
{ return(y);
}
int main()
{ 
 siz = id( 50);
 mat=rhoIII([ 50,siz],42);
 z = sum(mat);
 StdIO::print(z);
 return(0);
}
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking