@@ -14,6 +14,9 @@ private module Cached {
14
14
ReturnStep ( ) or
15
15
StoreStep ( TypeTrackerContent content ) { basicStoreStep ( _, _, content ) } or
16
16
LoadStep ( TypeTrackerContent content ) { basicLoadStep ( _, _, content ) } or
17
+ LoadStoreStep ( TypeTrackerContent load , TypeTrackerContent store ) {
18
+ basicLoadStoreStep ( _, _, load , store )
19
+ } or
17
20
JumpStep ( )
18
21
19
22
cached
@@ -75,6 +78,16 @@ private module Cached {
75
78
tt = noContentTypeTracker ( hasCall ) and
76
79
result = MkTypeTracker ( hasCall , storeContents )
77
80
)
81
+ or
82
+ exists (
83
+ TypeTrackerContent currentContent , TypeTrackerContent store , TypeTrackerContent load ,
84
+ boolean hasCall
85
+ |
86
+ step = LoadStoreStep ( pragma [ only_bind_into ] ( load ) , pragma [ only_bind_into ] ( store ) ) and
87
+ compatibleContents ( pragma [ only_bind_into ] ( currentContent ) , load ) and
88
+ tt = MkTypeTracker ( pragma [ only_bind_into ] ( hasCall ) , currentContent ) and
89
+ result = MkTypeTracker ( pragma [ only_bind_out ] ( hasCall ) , store )
90
+ )
78
91
}
79
92
80
93
pragma [ nomagic]
@@ -110,6 +123,16 @@ private module Cached {
110
123
tbt = noContentTypeBackTracker ( hasReturn ) and
111
124
result = MkTypeBackTracker ( hasReturn , loadContents )
112
125
)
126
+ or
127
+ exists (
128
+ TypeTrackerContent currentContent , TypeTrackerContent store , TypeTrackerContent load ,
129
+ boolean hasCall
130
+ |
131
+ step = LoadStoreStep ( pragma [ only_bind_into ] ( load ) , pragma [ only_bind_into ] ( store ) ) and
132
+ compatibleContents ( store , pragma [ only_bind_into ] ( currentContent ) ) and
133
+ tbt = MkTypeBackTracker ( pragma [ only_bind_into ] ( hasCall ) , currentContent ) and
134
+ result = MkTypeBackTracker ( pragma [ only_bind_out ] ( hasCall ) , load )
135
+ )
113
136
}
114
137
115
138
/**
@@ -146,6 +169,11 @@ private module Cached {
146
169
or
147
170
basicLoadStep ( nodeFrom , nodeTo , content ) and summary = LoadStep ( content )
148
171
)
172
+ or
173
+ exists ( TypeTrackerContent loadContent , TypeTrackerContent storeContent |
174
+ basicLoadStoreStep ( nodeFrom , nodeTo , loadContent , storeContent ) and
175
+ summary = LoadStoreStep ( loadContent , storeContent )
176
+ )
149
177
}
150
178
151
179
cached
@@ -208,6 +236,11 @@ class StepSummary extends TStepSummary {
208
236
or
209
237
exists ( TypeTrackerContent content | this = LoadStep ( content ) | result = "load " + content )
210
238
or
239
+ exists ( TypeTrackerContent load , TypeTrackerContent store |
240
+ this = LoadStoreStep ( load , store ) and
241
+ result = "load-store " + load + " -> " + store
242
+ )
243
+ or
211
244
this instanceof JumpStep and result = "jump"
212
245
}
213
246
}
0 commit comments