source: CIVL/mods/dev.civl.com/notes/dyscopes.txt@ 1aaefd4

main test-branch
Last change on this file since 1aaefd4 was aad342c, checked in by Stephen Siegel <siegel@…>, 3 years ago

Performing huge refactor to incorporate ABC, GMC, and SARL into CIVL repo and use Java modules.

git-svn-id: svn://vsl.cis.udel.edu/civl/trunk@5664 fb995dde-84ed-4084-dfe6-e5aef3e2452c

  • Property mode set to 100644
File size: 1.7 KB
RevLine 
[b9bfd33f]1
2Dyscopes are currently stored in an array in the state.
3This gives each an ID.
4Reachable dyscopes: call stacks always have reference to concrete dyscope.
5Pointers to anywhere:
6equality of two dyscopes:
7Type of value associated to a dyscope: struct {int}
8d1==d2 becomes d1.0==d2.0. This one survives renumbering, but not
9d1<d2. Sure, that becomes an uninterpreted function.
10What about
11
12d1==d2 --> d1.0==5.
13
14Renumbering: Apply permutation to d1.0?
15
16
17f(2)=f(3) ... need that to return false
18
19CIVL:evaluation of equality for dyscope types special handling
20 (also inequality, <, >)
21
22
23A concrete state has some concrete ordered list of dyscopes
24(0,1,2,...,n-1)
25and values of expressions of dyscope type are integers.
26Two concrete states are equivalent if there is a permutation
27of the integers 0..n-1 such that when applied to one state
28by permuting the dyscopes in the list and the id numbers in the values,
29you get the other state.
30
31A symbolic state represents a set of concrete states.
32Question is given two symbolic states, are they "equivalent"
33meaning given any concrete state cs1 in ss1, there is a concrete
34state cs2 in ss2 such that cs1 and cs2 are equivalent.
35And vice versa.
36
37what is the permutation applied to the symbolic state?
38
39var: dyscope ...
40
41var: array of T..
42
43example: (0 1 2)
44
45SS1:
46d1: X
47d2: Y
48d3: <1>
49d4: Z
50pc: X<Y && Y<1 && Z=2
51
52To show: let f be the permutation
53 X<Y iff f(X)<f(Y)
54 X=Y iff f(X)=f(Y)
55
56SS2:
57d1: X
58d2: Y
59d3: <2>
60d4: Z
61pc: X<Y && Y<2 && Z=0
62
63
64evaluation of operations on pointers or anything involving
65
66f(3)=X
67f(3)=f(4)
68
69X: arbitrary pointer
70X.0 : dyscope type
71X.0==f(3)
72
73Can we guarantee that f will only be applied to concrete integers?
74
75"I never want to see a conrete integer representing a dyscope taken out of f"
76
Note: See TracBrowser for help on using the repository browser.