rle.sac failure: LACSO vs. DCR causes crash in WLIR
|Created on||Nov 08, 2012 23:05|
cd sac/apex/rle sac@rattler:~/sac/apex/rle$ sac2c rle.sac -v1 stdopt/withloop_invariant_removal.c:861 Assertion "AVIS_DEFDEPTH(ID_AVIS(arg_node)) != DD_UNDEFINED" failed! reference to undefined identifier _lacso_17413 sac@rattler:~/sac/apex/rle$ sac2c rle.sac -v1 -nolacso sac2c -V sac@rattler:~/sac/apex/rle$ sac2c -V sac2c v1.00-beta (Haggis And Apple) developer rev 18019 linux-gnu_x86_64 (Thu Nov 8 17:08:16 EST 2012 by sac) I believe what is going on is this: 1. LACSO introduces a new scalar result value, which is never used in the calling context, but it IS used as an AVIS_SHAPE element in the called context. 2. DCR comes along, sees that the result value is unused in the caller, so deletes the N_funcond after the recursive call, which then marks the recursive call result dead. 3. Things eventually die in WLIR. I think the correct fix is to make DCR check for uses of the result value in AVIS son nodes, and mark the avis as live if that is the case. I don't like this approach, but have no better ideas yet.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information