svf-tools 1.0.849 → 1.0.850

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (284) hide show
  1. package/SVF-doxygen/html/IntervalExeState_8cpp_source.html +293 -217
  2. package/SVF-doxygen/html/IntervalExeState_8h.html +2 -0
  3. package/SVF-doxygen/html/IntervalExeState_8h_source.html +622 -435
  4. package/SVF-doxygen/html/RelationSolver_8cpp_source.html +60 -60
  5. package/SVF-doxygen/html/RelationSolver_8h_source.html +16 -16
  6. package/SVF-doxygen/html/SVFIR2ItvExeState_8cpp_source.html +10 -10
  7. package/SVF-doxygen/html/SVFIR2ItvExeState_8h_source.html +8 -8
  8. package/SVF-doxygen/html/annotated.html +215 -214
  9. package/SVF-doxygen/html/classSVF_1_1ExeState.html +9 -8
  10. package/SVF-doxygen/html/classSVF_1_1ExeState.png +0 -0
  11. package/SVF-doxygen/html/classSVF_1_1IntervalESBase-members.html +168 -0
  12. package/SVF-doxygen/html/classSVF_1_1IntervalESBase.html +2331 -0
  13. package/SVF-doxygen/html/classSVF_1_1IntervalESBase.png +0 -0
  14. package/SVF-doxygen/html/classSVF_1_1IntervalExeState-members.html +79 -62
  15. package/SVF-doxygen/html/classSVF_1_1IntervalExeState.html +497 -1381
  16. package/SVF-doxygen/html/classSVF_1_1IntervalExeState.png +0 -0
  17. package/SVF-doxygen/html/classSVF_1_1RelationSolver-members.html +8 -8
  18. package/SVF-doxygen/html/classSVF_1_1RelationSolver.html +100 -100
  19. package/SVF-doxygen/html/classSVF_1_1SVFIR2ItvExeState.html +29 -29
  20. package/SVF-doxygen/html/classes.html +232 -231
  21. package/SVF-doxygen/html/functions.html +2 -2
  22. package/SVF-doxygen/html/functions_a.html +1 -1
  23. package/SVF-doxygen/html/functions_b.html +4 -4
  24. package/SVF-doxygen/html/functions_c.html +2 -2
  25. package/SVF-doxygen/html/functions_e.html +4 -3
  26. package/SVF-doxygen/html/functions_f.html +3 -3
  27. package/SVF-doxygen/html/functions_func.html +1 -1
  28. package/SVF-doxygen/html/functions_func_b.html +4 -4
  29. package/SVF-doxygen/html/functions_func_c.html +2 -2
  30. package/SVF-doxygen/html/functions_func_e.html +3 -2
  31. package/SVF-doxygen/html/functions_func_g.html +27 -24
  32. package/SVF-doxygen/html/functions_func_h.html +4 -3
  33. package/SVF-doxygen/html/functions_func_i.html +16 -9
  34. package/SVF-doxygen/html/functions_func_j.html +1 -0
  35. package/SVF-doxygen/html/functions_func_l.html +6 -4
  36. package/SVF-doxygen/html/functions_func_m.html +1 -0
  37. package/SVF-doxygen/html/functions_func_n.html +6 -4
  38. package/SVF-doxygen/html/functions_func_o.html +17 -11
  39. package/SVF-doxygen/html/functions_func_p.html +3 -3
  40. package/SVF-doxygen/html/functions_func_r.html +1 -1
  41. package/SVF-doxygen/html/functions_func_s.html +2 -2
  42. package/SVF-doxygen/html/functions_func_t.html +2 -2
  43. package/SVF-doxygen/html/functions_func_w.html +4 -2
  44. package/SVF-doxygen/html/functions_func_~.html +3 -0
  45. package/SVF-doxygen/html/functions_g.html +24 -21
  46. package/SVF-doxygen/html/functions_h.html +6 -5
  47. package/SVF-doxygen/html/functions_i.html +21 -14
  48. package/SVF-doxygen/html/functions_j.html +1 -0
  49. package/SVF-doxygen/html/functions_l.html +10 -8
  50. package/SVF-doxygen/html/functions_m.html +1 -0
  51. package/SVF-doxygen/html/functions_n.html +5 -3
  52. package/SVF-doxygen/html/functions_o.html +18 -12
  53. package/SVF-doxygen/html/functions_p.html +17 -13
  54. package/SVF-doxygen/html/functions_r.html +7 -8
  55. package/SVF-doxygen/html/functions_rela_r.html +2 -1
  56. package/SVF-doxygen/html/functions_rela_s.html +1 -0
  57. package/SVF-doxygen/html/functions_s.html +15 -14
  58. package/SVF-doxygen/html/functions_t.html +5 -5
  59. package/SVF-doxygen/html/functions_type_l.html +1 -1
  60. package/SVF-doxygen/html/functions_type_v.html +1 -1
  61. package/SVF-doxygen/html/functions_v.html +7 -5
  62. package/SVF-doxygen/html/functions_vars.html +2 -2
  63. package/SVF-doxygen/html/functions_w.html +13 -9
  64. package/SVF-doxygen/html/functions_~.html +3 -0
  65. package/SVF-doxygen/html/hierarchy.html +2 -1
  66. package/SVF-doxygen/html/namespaceSVF.html +2 -0
  67. package/SVF-doxygen/html/search/all_0.js +2 -2
  68. package/SVF-doxygen/html/search/all_1.js +1 -1
  69. package/SVF-doxygen/html/search/all_10.js +325 -325
  70. package/SVF-doxygen/html/search/all_11.js +224 -224
  71. package/SVF-doxygen/html/search/all_12.js +552 -552
  72. package/SVF-doxygen/html/search/all_13.js +190 -190
  73. package/SVF-doxygen/html/search/all_14.js +67 -67
  74. package/SVF-doxygen/html/search/all_15.js +168 -168
  75. package/SVF-doxygen/html/search/all_16.js +63 -63
  76. package/SVF-doxygen/html/search/all_17.js +1 -1
  77. package/SVF-doxygen/html/search/all_18.js +1 -1
  78. package/SVF-doxygen/html/search/all_19.js +11 -11
  79. package/SVF-doxygen/html/search/all_1a.js +174 -173
  80. package/SVF-doxygen/html/search/all_2.js +4 -4
  81. package/SVF-doxygen/html/search/all_3.js +2 -2
  82. package/SVF-doxygen/html/search/all_5.js +2 -2
  83. package/SVF-doxygen/html/search/all_6.js +1 -1
  84. package/SVF-doxygen/html/search/all_7.js +6 -6
  85. package/SVF-doxygen/html/search/all_8.js +2 -2
  86. package/SVF-doxygen/html/search/all_9.js +406 -405
  87. package/SVF-doxygen/html/search/all_a.js +46 -46
  88. package/SVF-doxygen/html/search/all_b.js +26 -26
  89. package/SVF-doxygen/html/search/all_c.js +115 -115
  90. package/SVF-doxygen/html/search/all_d.js +197 -197
  91. package/SVF-doxygen/html/search/all_e.js +207 -207
  92. package/SVF-doxygen/html/search/all_f.js +116 -116
  93. package/SVF-doxygen/html/search/classes_0.js +26 -26
  94. package/SVF-doxygen/html/search/classes_1.js +9 -9
  95. package/SVF-doxygen/html/search/classes_10.js +73 -73
  96. package/SVF-doxygen/html/search/classes_11.js +15 -15
  97. package/SVF-doxygen/html/search/classes_12.js +2 -2
  98. package/SVF-doxygen/html/search/classes_13.js +10 -10
  99. package/SVF-doxygen/html/search/classes_14.js +14 -14
  100. package/SVF-doxygen/html/search/classes_15.js +1 -1
  101. package/SVF-doxygen/html/search/classes_2.js +81 -81
  102. package/SVF-doxygen/html/search/classes_3.js +37 -37
  103. package/SVF-doxygen/html/search/classes_4.js +9 -9
  104. package/SVF-doxygen/html/search/classes_5.js +28 -28
  105. package/SVF-doxygen/html/search/classes_6.js +104 -104
  106. package/SVF-doxygen/html/search/classes_7.js +34 -34
  107. package/SVF-doxygen/html/search/classes_8.js +57 -56
  108. package/SVF-doxygen/html/search/classes_9.js +1 -1
  109. package/SVF-doxygen/html/search/classes_a.js +12 -12
  110. package/SVF-doxygen/html/search/classes_b.js +29 -29
  111. package/SVF-doxygen/html/search/classes_c.js +6 -6
  112. package/SVF-doxygen/html/search/classes_d.js +18 -18
  113. package/SVF-doxygen/html/search/classes_e.js +36 -36
  114. package/SVF-doxygen/html/search/classes_f.js +25 -25
  115. package/SVF-doxygen/html/search/defines_0.js +3 -3
  116. package/SVF-doxygen/html/search/defines_1.js +2 -2
  117. package/SVF-doxygen/html/search/defines_2.js +30 -30
  118. package/SVF-doxygen/html/search/defines_3.js +20 -20
  119. package/SVF-doxygen/html/search/defines_4.js +2 -2
  120. package/SVF-doxygen/html/search/defines_5.js +4 -4
  121. package/SVF-doxygen/html/search/defines_6.js +2 -2
  122. package/SVF-doxygen/html/search/defines_7.js +5 -5
  123. package/SVF-doxygen/html/search/defines_8.js +11 -11
  124. package/SVF-doxygen/html/search/defines_9.js +9 -9
  125. package/SVF-doxygen/html/search/defines_a.js +2 -2
  126. package/SVF-doxygen/html/search/defines_b.js +1 -1
  127. package/SVF-doxygen/html/search/defines_c.js +3 -3
  128. package/SVF-doxygen/html/search/defines_d.js +2 -2
  129. package/SVF-doxygen/html/search/defines_e.js +7 -7
  130. package/SVF-doxygen/html/search/defines_f.js +3 -3
  131. package/SVF-doxygen/html/search/enums_0.js +3 -3
  132. package/SVF-doxygen/html/search/enums_1.js +2 -2
  133. package/SVF-doxygen/html/search/enums_10.js +1 -1
  134. package/SVF-doxygen/html/search/enums_11.js +1 -1
  135. package/SVF-doxygen/html/search/enums_2.js +8 -8
  136. package/SVF-doxygen/html/search/enums_3.js +1 -1
  137. package/SVF-doxygen/html/search/enums_4.js +3 -3
  138. package/SVF-doxygen/html/search/enums_5.js +1 -1
  139. package/SVF-doxygen/html/search/enums_6.js +2 -2
  140. package/SVF-doxygen/html/search/enums_7.js +2 -2
  141. package/SVF-doxygen/html/search/enums_8.js +4 -4
  142. package/SVF-doxygen/html/search/enums_9.js +1 -1
  143. package/SVF-doxygen/html/search/enums_a.js +1 -1
  144. package/SVF-doxygen/html/search/enums_b.js +7 -7
  145. package/SVF-doxygen/html/search/enums_c.js +1 -1
  146. package/SVF-doxygen/html/search/enums_d.js +4 -4
  147. package/SVF-doxygen/html/search/enums_e.js +2 -2
  148. package/SVF-doxygen/html/search/enums_f.js +4 -4
  149. package/SVF-doxygen/html/search/enumvalues_0.js +14 -14
  150. package/SVF-doxygen/html/search/enumvalues_1.js +14 -14
  151. package/SVF-doxygen/html/search/enumvalues_10.js +35 -35
  152. package/SVF-doxygen/html/search/enumvalues_11.js +3 -3
  153. package/SVF-doxygen/html/search/enumvalues_12.js +10 -10
  154. package/SVF-doxygen/html/search/enumvalues_13.js +1 -1
  155. package/SVF-doxygen/html/search/enumvalues_14.js +1 -1
  156. package/SVF-doxygen/html/search/enumvalues_15.js +3 -3
  157. package/SVF-doxygen/html/search/enumvalues_2.js +36 -36
  158. package/SVF-doxygen/html/search/enumvalues_3.js +13 -13
  159. package/SVF-doxygen/html/search/enumvalues_4.js +2 -2
  160. package/SVF-doxygen/html/search/enumvalues_5.js +47 -47
  161. package/SVF-doxygen/html/search/enumvalues_6.js +6 -6
  162. package/SVF-doxygen/html/search/enumvalues_7.js +8 -8
  163. package/SVF-doxygen/html/search/enumvalues_8.js +23 -23
  164. package/SVF-doxygen/html/search/enumvalues_9.js +6 -6
  165. package/SVF-doxygen/html/search/enumvalues_a.js +15 -15
  166. package/SVF-doxygen/html/search/enumvalues_b.js +11 -11
  167. package/SVF-doxygen/html/search/enumvalues_c.js +5 -5
  168. package/SVF-doxygen/html/search/enumvalues_d.js +18 -18
  169. package/SVF-doxygen/html/search/enumvalues_e.js +9 -9
  170. package/SVF-doxygen/html/search/enumvalues_f.js +45 -45
  171. package/SVF-doxygen/html/search/files_0.js +13 -13
  172. package/SVF-doxygen/html/search/files_1.js +7 -7
  173. package/SVF-doxygen/html/search/files_10.js +8 -8
  174. package/SVF-doxygen/html/search/files_11.js +8 -8
  175. package/SVF-doxygen/html/search/files_12.js +2 -2
  176. package/SVF-doxygen/html/search/files_2.js +57 -57
  177. package/SVF-doxygen/html/search/files_3.js +14 -14
  178. package/SVF-doxygen/html/search/files_4.js +5 -5
  179. package/SVF-doxygen/html/search/files_5.js +13 -13
  180. package/SVF-doxygen/html/search/files_6.js +9 -9
  181. package/SVF-doxygen/html/search/files_7.js +14 -14
  182. package/SVF-doxygen/html/search/files_8.js +13 -13
  183. package/SVF-doxygen/html/search/files_9.js +18 -18
  184. package/SVF-doxygen/html/search/files_a.js +3 -3
  185. package/SVF-doxygen/html/search/files_b.js +2 -2
  186. package/SVF-doxygen/html/search/files_c.js +20 -20
  187. package/SVF-doxygen/html/search/files_d.js +4 -4
  188. package/SVF-doxygen/html/search/files_e.js +62 -62
  189. package/SVF-doxygen/html/search/files_f.js +8 -8
  190. package/SVF-doxygen/html/search/functions_0.js +13 -13
  191. package/SVF-doxygen/html/search/functions_1.js +362 -362
  192. package/SVF-doxygen/html/search/functions_10.js +140 -140
  193. package/SVF-doxygen/html/search/functions_11.js +139 -139
  194. package/SVF-doxygen/html/search/functions_12.js +288 -288
  195. package/SVF-doxygen/html/search/functions_13.js +59 -59
  196. package/SVF-doxygen/html/search/functions_14.js +39 -39
  197. package/SVF-doxygen/html/search/functions_15.js +71 -71
  198. package/SVF-doxygen/html/search/functions_16.js +32 -32
  199. package/SVF-doxygen/html/search/functions_17.js +3 -3
  200. package/SVF-doxygen/html/search/functions_18.js +174 -173
  201. package/SVF-doxygen/html/search/functions_2.js +89 -89
  202. package/SVF-doxygen/html/search/functions_3.js +261 -261
  203. package/SVF-doxygen/html/search/functions_4.js +78 -78
  204. package/SVF-doxygen/html/search/functions_5.js +53 -53
  205. package/SVF-doxygen/html/search/functions_6.js +60 -60
  206. package/SVF-doxygen/html/search/functions_7.js +855 -855
  207. package/SVF-doxygen/html/search/functions_8.js +148 -148
  208. package/SVF-doxygen/html/search/functions_9.js +421 -420
  209. package/SVF-doxygen/html/search/functions_a.js +30 -30
  210. package/SVF-doxygen/html/search/functions_b.js +2 -2
  211. package/SVF-doxygen/html/search/functions_c.js +25 -25
  212. package/SVF-doxygen/html/search/functions_d.js +79 -79
  213. package/SVF-doxygen/html/search/functions_e.js +35 -35
  214. package/SVF-doxygen/html/search/functions_f.js +56 -56
  215. package/SVF-doxygen/html/search/namespaces_0.js +1 -1
  216. package/SVF-doxygen/html/search/namespaces_1.js +7 -7
  217. package/SVF-doxygen/html/search/related_0.js +2 -2
  218. package/SVF-doxygen/html/search/related_1.js +2 -2
  219. package/SVF-doxygen/html/search/related_2.js +3 -3
  220. package/SVF-doxygen/html/search/related_3.js +2 -2
  221. package/SVF-doxygen/html/search/related_4.js +2 -2
  222. package/SVF-doxygen/html/search/related_5.js +1 -1
  223. package/SVF-doxygen/html/search/related_6.js +2 -2
  224. package/SVF-doxygen/html/search/related_7.js +4 -4
  225. package/SVF-doxygen/html/search/related_8.js +2 -2
  226. package/SVF-doxygen/html/search/related_9.js +4 -4
  227. package/SVF-doxygen/html/search/related_a.js +19 -19
  228. package/SVF-doxygen/html/search/related_b.js +4 -4
  229. package/SVF-doxygen/html/search/related_c.js +2 -2
  230. package/SVF-doxygen/html/search/related_d.js +12 -12
  231. package/SVF-doxygen/html/search/related_e.js +2 -2
  232. package/SVF-doxygen/html/search/related_f.js +2 -2
  233. package/SVF-doxygen/html/search/typedefs_0.js +19 -19
  234. package/SVF-doxygen/html/search/typedefs_1.js +26 -26
  235. package/SVF-doxygen/html/search/typedefs_10.js +62 -62
  236. package/SVF-doxygen/html/search/typedefs_11.js +13 -13
  237. package/SVF-doxygen/html/search/typedefs_12.js +11 -11
  238. package/SVF-doxygen/html/search/typedefs_13.js +33 -33
  239. package/SVF-doxygen/html/search/typedefs_14.js +8 -8
  240. package/SVF-doxygen/html/search/typedefs_2.js +129 -129
  241. package/SVF-doxygen/html/search/typedefs_3.js +39 -39
  242. package/SVF-doxygen/html/search/typedefs_4.js +17 -17
  243. package/SVF-doxygen/html/search/typedefs_5.js +41 -41
  244. package/SVF-doxygen/html/search/typedefs_6.js +56 -56
  245. package/SVF-doxygen/html/search/typedefs_7.js +44 -44
  246. package/SVF-doxygen/html/search/typedefs_8.js +1 -1
  247. package/SVF-doxygen/html/search/typedefs_9.js +6 -6
  248. package/SVF-doxygen/html/search/typedefs_a.js +29 -29
  249. package/SVF-doxygen/html/search/typedefs_b.js +29 -29
  250. package/SVF-doxygen/html/search/typedefs_c.js +41 -41
  251. package/SVF-doxygen/html/search/typedefs_d.js +14 -14
  252. package/SVF-doxygen/html/search/typedefs_e.js +52 -52
  253. package/SVF-doxygen/html/search/typedefs_f.js +14 -14
  254. package/SVF-doxygen/html/search/variables_0.js +151 -151
  255. package/SVF-doxygen/html/search/variables_1.js +75 -75
  256. package/SVF-doxygen/html/search/variables_10.js +98 -98
  257. package/SVF-doxygen/html/search/variables_11.js +45 -45
  258. package/SVF-doxygen/html/search/variables_12.js +90 -90
  259. package/SVF-doxygen/html/search/variables_13.js +74 -74
  260. package/SVF-doxygen/html/search/variables_14.js +14 -14
  261. package/SVF-doxygen/html/search/variables_15.js +49 -49
  262. package/SVF-doxygen/html/search/variables_16.js +9 -9
  263. package/SVF-doxygen/html/search/variables_17.js +1 -1
  264. package/SVF-doxygen/html/search/variables_18.js +2 -2
  265. package/SVF-doxygen/html/search/variables_2.js +38 -38
  266. package/SVF-doxygen/html/search/variables_3.js +142 -142
  267. package/SVF-doxygen/html/search/variables_4.js +50 -50
  268. package/SVF-doxygen/html/search/variables_5.js +37 -37
  269. package/SVF-doxygen/html/search/variables_6.js +66 -66
  270. package/SVF-doxygen/html/search/variables_7.js +34 -34
  271. package/SVF-doxygen/html/search/variables_8.js +7 -7
  272. package/SVF-doxygen/html/search/variables_9.js +78 -78
  273. package/SVF-doxygen/html/search/variables_a.js +4 -4
  274. package/SVF-doxygen/html/search/variables_b.js +10 -10
  275. package/SVF-doxygen/html/search/variables_c.js +45 -45
  276. package/SVF-doxygen/html/search/variables_d.js +55 -55
  277. package/SVF-doxygen/html/search/variables_e.js +123 -123
  278. package/SVF-doxygen/html/search/variables_f.js +30 -30
  279. package/SVF-doxygen/html/structstd_1_1hash_3_01SVF_1_1IntervalExeState_01_4.html +6 -6
  280. package/package.json +1 -1
  281. package/svf/include/AbstractExecution/IntervalExeState.h +274 -102
  282. package/svf/include/AbstractExecution/RelationSolver.h +9 -9
  283. package/svf/lib/AbstractExecution/IntervalExeState.cpp +85 -14
  284. package/svf/lib/AbstractExecution/RelationSolver.cpp +22 -22
@@ -51,38 +51,34 @@
51
51
 
52
52
  namespace SVF
53
53
  {
54
-
55
- class IntervalExeState : public ExeState
54
+ class IntervalESBase: public ExeState
56
55
  {
57
56
  friend class SVFIR2ItvExeState;
58
57
  friend class RelationSolver;
59
-
60
58
  public:
61
59
  typedef Map<u32_t, IntervalValue> VarToValMap;
62
60
 
63
61
  typedef VarToValMap LocToValMap;
64
62
 
65
- static IntervalExeState globalES;
66
-
67
63
  public:
68
64
  /// default constructor
69
- IntervalExeState() : ExeState(ExeState::IntervalK) {}
65
+ IntervalESBase() : ExeState(ExeState::IntervalK) {}
70
66
 
71
- IntervalExeState(VarToValMap &_varToValMap, LocToValMap &_locToValMap) : ExeState(ExeState::IntervalK),
67
+ IntervalESBase(VarToValMap &_varToValMap, LocToValMap &_locToValMap) : ExeState(ExeState::IntervalK),
72
68
  _varToItvVal(_varToValMap),
73
69
  _locToItvVal(_locToValMap) {}
74
70
 
75
71
  /// copy constructor
76
- IntervalExeState(const IntervalExeState &rhs) : ExeState(rhs), _varToItvVal(rhs.getVarToVal()),
72
+ IntervalESBase(const IntervalESBase &rhs) : ExeState(rhs), _varToItvVal(rhs.getVarToVal()),
77
73
  _locToItvVal(rhs.getLocToVal())
78
74
  {
79
75
 
80
76
  }
81
77
 
82
- virtual ~IntervalExeState() = default;
78
+ virtual ~IntervalESBase() = default;
83
79
 
84
80
 
85
- IntervalExeState &operator=(const IntervalExeState &rhs)
81
+ IntervalESBase &operator=(const IntervalESBase &rhs)
86
82
  {
87
83
  if (rhs != *this)
88
84
  {
@@ -94,7 +90,7 @@ public:
94
90
  }
95
91
 
96
92
  /// move constructor
97
- IntervalExeState(IntervalExeState &&rhs) : ExeState(std::move(rhs)),
93
+ IntervalESBase(IntervalESBase &&rhs) : ExeState(std::move(rhs)),
98
94
  _varToItvVal(std::move(rhs._varToItvVal)),
99
95
  _locToItvVal(std::move(rhs._locToItvVal))
100
96
  {
@@ -102,7 +98,7 @@ public:
102
98
  }
103
99
 
104
100
  /// operator= move constructor
105
- IntervalExeState &operator=(IntervalExeState &&rhs)
101
+ IntervalESBase &operator=(IntervalESBase &&rhs)
106
102
  {
107
103
  if (&rhs != this)
108
104
  {
@@ -114,9 +110,9 @@ public:
114
110
  }
115
111
 
116
112
  /// Set all value bottom
117
- IntervalExeState bottom() const
113
+ IntervalESBase bottom() const
118
114
  {
119
- IntervalExeState inv = *this;
115
+ IntervalESBase inv = *this;
120
116
  for (auto &item: inv._varToItvVal)
121
117
  {
122
118
  item.second.set_to_bottom();
@@ -125,9 +121,9 @@ public:
125
121
  }
126
122
 
127
123
  /// Set all value top
128
- IntervalExeState top() const
124
+ IntervalESBase top() const
129
125
  {
130
- IntervalExeState inv = *this;
126
+ IntervalESBase inv = *this;
131
127
  for (auto &item: inv._varToItvVal)
132
128
  {
133
129
  item.second.set_to_top();
@@ -136,9 +132,9 @@ public:
136
132
  }
137
133
 
138
134
  /// Copy some values and return a new IntervalExeState
139
- IntervalExeState sliceState(Set<u32_t> &sl)
135
+ IntervalESBase sliceState(Set<u32_t> &sl)
140
136
  {
141
- IntervalExeState inv;
137
+ IntervalESBase inv;
142
138
  for (u32_t id: sl)
143
139
  {
144
140
  inv._varToItvVal[id] = _varToItvVal[id];
@@ -156,51 +152,37 @@ public:
156
152
  /// get memory addresses of variable
157
153
  Addrs &getAddrs(u32_t id) override
158
154
  {
159
- auto it = _varToAddrs.find(id);
160
- if (it != _varToAddrs.end())
161
- return it->second;
162
- else
163
- return globalES._varToAddrs[id];
155
+ return _varToAddrs[id];
164
156
  }
165
157
 
166
158
  /// get interval value of variable
167
- inline IntervalValue &operator[](u32_t varId)
159
+ inline virtual IntervalValue &operator[](u32_t varId)
168
160
  {
169
- auto localIt = _varToItvVal.find(varId);
170
- if(localIt != _varToItvVal.end())
171
- return localIt->second;
172
- else
173
- {
174
- return globalES._varToItvVal[varId];
175
- }
161
+ return _varToItvVal[varId];
176
162
  }
177
163
 
178
164
  /// whether the variable is in varToAddrs table
179
165
  inline bool inVarToAddrsTable(u32_t id) const override
180
166
  {
181
- return _varToAddrs.find(id) != _varToAddrs.end() ||
182
- globalES._varToAddrs.find(id) != globalES._varToAddrs.end();
167
+ return _varToAddrs.find(id) != _varToAddrs.end();
183
168
  }
184
169
 
185
170
  /// whether the variable is in varToVal table
186
- inline bool inVarToValTable(u32_t id) const
171
+ inline virtual bool inVarToValTable(u32_t id) const
187
172
  {
188
- return _varToItvVal.find(id) != _varToItvVal.end() ||
189
- globalES._varToItvVal.find(id) != globalES._varToItvVal.end();
173
+ return _varToItvVal.find(id) != _varToItvVal.end();
190
174
  }
191
175
 
192
176
  /// whether the memory address stores memory addresses
193
177
  inline bool inLocToAddrsTable(u32_t id) const override
194
178
  {
195
- return _locToAddrs.find(id) != _locToAddrs.end() ||
196
- globalES._locToAddrs.find(id) != globalES._locToAddrs.end();
179
+ return _locToAddrs.find(id) != _locToAddrs.end();
197
180
  }
198
181
 
199
182
  /// whether the memory address stores interval value
200
- inline bool inLocToValTable(u32_t id) const
183
+ inline virtual bool inLocToValTable(u32_t id) const
201
184
  {
202
- return _locToItvVal.find(id) != _locToItvVal.end() ||
203
- globalES._locToItvVal.find(id) != globalES._locToItvVal.end();
185
+ return _locToItvVal.find(id) != _locToItvVal.end();
204
186
  }
205
187
 
206
188
  /// get var2val map
@@ -215,50 +197,25 @@ public:
215
197
  return _locToItvVal;
216
198
  }
217
199
 
218
- inline bool inLocalLocToValTable(u32_t id) const
219
- {
220
- return _locToItvVal.find(id) != _locToItvVal.end();
221
- }
222
-
223
- inline bool inLocalLocToAddrsTable(u32_t id) const
224
- {
225
- return _locToAddrs.find(id) != _locToAddrs.end();
226
- }
227
-
228
200
  public:
229
201
 
230
- inline void cpyItvToLocal(u32_t varId)
231
- {
232
- auto localIt = _varToItvVal.find(varId);
233
- // local already have varId
234
- if (localIt != _varToItvVal.end()) return;
235
- auto globIt = globalES._varToItvVal.find(varId);
236
- if (globIt != globalES._varToItvVal.end())
237
- {
238
- _varToItvVal[varId] = globIt->second;
239
- }
240
- }
241
-
242
202
  /// domain widen with other, and return the widened domain
243
- IntervalExeState widening(const IntervalExeState &other);
203
+ IntervalESBase widening(const IntervalESBase &other);
244
204
 
245
205
  /// domain narrow with other, and return the narrowed domain
246
- IntervalExeState narrowing(const IntervalExeState &other);
206
+ IntervalESBase narrowing(const IntervalESBase &other);
247
207
 
248
208
  /// domain widen with other, important! other widen this.
249
- void widenWith(const IntervalExeState &other);
209
+ void widenWith(const IntervalESBase &other);
250
210
 
251
211
  /// domain join with other, important! other widen this.
252
- void joinWith(const IntervalExeState &other);
212
+ void joinWith(const IntervalESBase &other);
253
213
 
254
214
  /// domain narrow with other, important! other widen this.
255
- void narrowWith(const IntervalExeState &other);
215
+ void narrowWith(const IntervalESBase &other);
256
216
 
257
217
  /// domain meet with other, important! other widen this.
258
- void meetWith(const IntervalExeState &other);
259
-
260
- /// domain meet with other varToValMap
261
- void meetWith(VarToValMap *other);
218
+ void meetWith(const IntervalESBase &other);
262
219
 
263
220
 
264
221
  /// Return int value from an expression if it is a numeral, otherwise return an approximate value
@@ -306,7 +263,7 @@ public:
306
263
  _locToItvVal[objId] = val;
307
264
  }
308
265
 
309
- inline IntervalValue &load(u32_t addr)
266
+ inline virtual IntervalValue &load(u32_t addr)
310
267
  {
311
268
  assert(isVirtualMemAddress(addr) && "not virtual address?");
312
269
  u32_t objId = getInternalID(addr);
@@ -315,15 +272,11 @@ public:
315
272
  return it->second;
316
273
  else
317
274
  {
318
- auto globIt = globalES._locToItvVal.find(objId);
319
- if(globIt != globalES._locToItvVal.end())
320
- return globIt->second;
321
- else
322
- return _locToItvVal[objId];
275
+ return _locToItvVal[objId];
323
276
  }
324
277
  }
325
278
 
326
- inline Addrs &loadAddrs(u32_t addr) override
279
+ inline virtual Addrs &loadAddrs(u32_t addr) override
327
280
  {
328
281
  assert(isVirtualMemAddress(addr) && "not virtual address?");
329
282
  u32_t objId = getInternalID(addr);
@@ -332,41 +285,29 @@ public:
332
285
  return it->second;
333
286
  else
334
287
  {
335
- auto globIt = globalES._locToAddrs.find(objId);
336
- if(globIt != globalES._locToAddrs.end())
337
- return globIt->second;
338
- else
339
- return _locToAddrs[objId];
288
+ return _locToAddrs[objId];
340
289
  }
341
290
  }
342
291
 
343
- inline IntervalValue& getLocToVal(u32_t id)
292
+ inline virtual IntervalValue& getLocToVal(u32_t id)
344
293
  {
345
294
  auto it = _locToItvVal.find(id);
346
295
  if(it != _locToItvVal.end())
347
296
  return it->second;
348
297
  else
349
298
  {
350
- auto globIt = globalES._locToItvVal.find(id);
351
- if(globIt != globalES._locToItvVal.end())
352
- return globIt->second;
353
- else
354
- return _locToItvVal[id];
299
+ return _locToItvVal[id];
355
300
  }
356
301
  }
357
302
 
358
- inline Addrs& getLocAddrs(u32_t id)
303
+ inline virtual Addrs& getLocAddrs(u32_t id)
359
304
  {
360
305
  auto it = _locToAddrs.find(id);
361
306
  if(it != _locToAddrs.end())
362
307
  return it->second;
363
308
  else
364
309
  {
365
- auto globIt = globalES._locToAddrs.find(id);
366
- if(globIt != globalES._locToAddrs.end())
367
- return globIt->second;
368
- else
369
- return _locToAddrs[id];
310
+ return _locToAddrs[id];
370
311
  }
371
312
  }
372
313
 
@@ -378,7 +319,7 @@ public:
378
319
  return "";
379
320
  }
380
321
 
381
- bool equals(const IntervalExeState &other) const;
322
+ bool equals(const IntervalESBase &other) const;
382
323
 
383
324
  static bool eqVarToValMap(const VarToValMap &lhs, const VarToValMap &rhs)
384
325
  {
@@ -426,24 +367,24 @@ public:
426
367
 
427
368
  using ExeState::operator==;
428
369
  using ExeState::operator!=;
429
- bool operator==(const IntervalExeState &rhs) const
370
+ bool operator==(const IntervalESBase &rhs) const
430
371
  {
431
372
  return ExeState::operator==(rhs) && eqVarToValMap(_varToItvVal, rhs.getVarToVal()) &&
432
373
  eqVarToValMap(_locToItvVal, rhs.getLocToVal());
433
374
  }
434
375
 
435
- bool operator!=(const IntervalExeState &rhs) const
376
+ bool operator!=(const IntervalESBase &rhs) const
436
377
  {
437
378
  return !(*this == rhs);
438
379
  }
439
380
 
440
- bool operator<(const IntervalExeState &rhs) const
381
+ bool operator<(const IntervalESBase &rhs) const
441
382
  {
442
383
  return !(*this >= rhs);
443
384
  }
444
385
 
445
386
 
446
- bool operator>=(const IntervalExeState &rhs) const
387
+ bool operator>=(const IntervalESBase &rhs) const
447
388
  {
448
389
  return geqVarToValMap(_varToItvVal, rhs.getVarToVal()) && geqVarToValMap(_locToItvVal, rhs.getLocToVal());
449
390
  }
@@ -457,11 +398,242 @@ public:
457
398
  }
458
399
 
459
400
 
460
- private:
401
+ protected:
461
402
  void printTable(const VarToValMap &table, std::ostream &oss) const;
462
403
 
463
404
  void printTable(const VarToAddrs &table, std::ostream &oss) const;
464
405
  };
406
+
407
+ class IntervalExeState : public IntervalESBase
408
+ {
409
+ friend class SVFIR2ItvExeState;
410
+ friend class RelationSolver;
411
+
412
+ public:
413
+ static IntervalExeState globalES;
414
+
415
+ public:
416
+ /// default constructor
417
+ IntervalExeState() : IntervalESBase() {}
418
+
419
+ IntervalExeState(VarToValMap &_varToValMap, LocToValMap &_locToValMap) : IntervalESBase(_varToValMap, _locToValMap) {}
420
+
421
+ /// copy constructor
422
+ IntervalExeState(const IntervalExeState &rhs) : IntervalESBase(rhs)
423
+ {
424
+
425
+ }
426
+
427
+ virtual ~IntervalExeState() = default;
428
+
429
+
430
+ IntervalExeState &operator=(const IntervalExeState &rhs)
431
+ {
432
+ IntervalESBase::operator=(rhs);
433
+ return *this;
434
+ }
435
+
436
+ /// move constructor
437
+ IntervalExeState(IntervalExeState &&rhs) : IntervalESBase(std::move(rhs))
438
+ {
439
+
440
+ }
441
+
442
+ /// operator= move constructor
443
+ IntervalExeState &operator=(IntervalExeState &&rhs)
444
+ {
445
+ IntervalESBase::operator=(std::move(rhs));
446
+ return *this;
447
+ }
448
+
449
+ public:
450
+
451
+ /// get memory addresses of variable
452
+ Addrs &getAddrs(u32_t id) override
453
+ {
454
+ auto it = _varToAddrs.find(id);
455
+ if (it != _varToAddrs.end())
456
+ return it->second;
457
+ else
458
+ return globalES._varToAddrs[id];
459
+ }
460
+
461
+ /// get interval value of variable
462
+ inline IntervalValue &operator[](u32_t varId) override
463
+ {
464
+ auto localIt = _varToItvVal.find(varId);
465
+ if(localIt != _varToItvVal.end())
466
+ return localIt->second;
467
+ else
468
+ {
469
+ return globalES._varToItvVal[varId];
470
+ }
471
+ }
472
+
473
+ /// whether the variable is in varToAddrs table
474
+ inline bool inVarToAddrsTable(u32_t id) const override
475
+ {
476
+ return _varToAddrs.find(id) != _varToAddrs.end() ||
477
+ globalES._varToAddrs.find(id) != globalES._varToAddrs.end();
478
+ }
479
+
480
+ /// whether the variable is in varToVal table
481
+ inline bool inVarToValTable(u32_t id) const override
482
+ {
483
+ return _varToItvVal.find(id) != _varToItvVal.end() ||
484
+ globalES._varToItvVal.find(id) != globalES._varToItvVal.end();
485
+ }
486
+
487
+ /// whether the memory address stores memory addresses
488
+ inline bool inLocToAddrsTable(u32_t id) const override
489
+ {
490
+ return _locToAddrs.find(id) != _locToAddrs.end() ||
491
+ globalES._locToAddrs.find(id) != globalES._locToAddrs.end();
492
+ }
493
+
494
+ /// whether the memory address stores interval value
495
+ inline bool inLocToValTable(u32_t id) const override
496
+ {
497
+ return _locToItvVal.find(id) != _locToItvVal.end() ||
498
+ globalES._locToItvVal.find(id) != globalES._locToItvVal.end();
499
+ }
500
+
501
+ inline bool inLocalLocToValTable(u32_t id) const
502
+ {
503
+ return _locToItvVal.find(id) != _locToItvVal.end();
504
+ }
505
+
506
+ inline bool inLocalLocToAddrsTable(u32_t id) const
507
+ {
508
+ return _locToAddrs.find(id) != _locToAddrs.end();
509
+ }
510
+
511
+ public:
512
+
513
+ inline void cpyItvToLocal(u32_t varId)
514
+ {
515
+ auto localIt = _varToItvVal.find(varId);
516
+ // local already have varId
517
+ if (localIt != _varToItvVal.end()) return;
518
+ auto globIt = globalES._varToItvVal.find(varId);
519
+ if (globIt != globalES._varToItvVal.end())
520
+ {
521
+ _varToItvVal[varId] = globIt->second;
522
+ }
523
+ }
524
+
525
+ /// domain widen with other, and return the widened domain
526
+ IntervalExeState widening(const IntervalExeState &other);
527
+
528
+ /// domain narrow with other, and return the narrowed domain
529
+ IntervalExeState narrowing(const IntervalExeState &other);
530
+
531
+ /// domain widen with other, important! other widen this.
532
+ void widenWith(const IntervalExeState &other);
533
+
534
+ /// domain join with other, important! other widen this.
535
+ void joinWith(const IntervalExeState &other);
536
+
537
+ /// domain narrow with other, important! other widen this.
538
+ void narrowWith(const IntervalExeState &other);
539
+
540
+ /// domain meet with other, important! other widen this.
541
+ void meetWith(const IntervalExeState &other);
542
+
543
+ u32_t hash() const override;
544
+
545
+ public:
546
+
547
+ inline IntervalValue &load(u32_t addr) override
548
+ {
549
+ assert(isVirtualMemAddress(addr) && "not virtual address?");
550
+ u32_t objId = getInternalID(addr);
551
+ auto it = _locToItvVal.find(objId);
552
+ if(it != _locToItvVal.end())
553
+ return it->second;
554
+ else
555
+ {
556
+ auto globIt = globalES._locToItvVal.find(objId);
557
+ if(globIt != globalES._locToItvVal.end())
558
+ return globIt->second;
559
+ else
560
+ return _locToItvVal[objId];
561
+ }
562
+ }
563
+
564
+ inline Addrs &loadAddrs(u32_t addr) override
565
+ {
566
+ assert(isVirtualMemAddress(addr) && "not virtual address?");
567
+ u32_t objId = getInternalID(addr);
568
+ auto it = _locToAddrs.find(objId);
569
+ if(it != _locToAddrs.end())
570
+ return it->second;
571
+ else
572
+ {
573
+ auto globIt = globalES._locToAddrs.find(objId);
574
+ if(globIt != globalES._locToAddrs.end())
575
+ return globIt->second;
576
+ else
577
+ return _locToAddrs[objId];
578
+ }
579
+ }
580
+
581
+ inline IntervalValue& getLocToVal(u32_t id) override
582
+ {
583
+ auto it = _locToItvVal.find(id);
584
+ if(it != _locToItvVal.end())
585
+ return it->second;
586
+ else
587
+ {
588
+ auto globIt = globalES._locToItvVal.find(id);
589
+ if(globIt != globalES._locToItvVal.end())
590
+ return globIt->second;
591
+ else
592
+ return _locToItvVal[id];
593
+ }
594
+ }
595
+
596
+ inline Addrs& getLocAddrs(u32_t id) override
597
+ {
598
+ auto it = _locToAddrs.find(id);
599
+ if(it != _locToAddrs.end())
600
+ return it->second;
601
+ else
602
+ {
603
+ auto globIt = globalES._locToAddrs.find(id);
604
+ if(globIt != globalES._locToAddrs.end())
605
+ return globIt->second;
606
+ else
607
+ return _locToAddrs[id];
608
+ }
609
+ }
610
+
611
+ bool equals(const IntervalExeState &other) const;
612
+
613
+ using ExeState::operator==;
614
+ using ExeState::operator!=;
615
+ bool operator==(const IntervalExeState &rhs) const
616
+ {
617
+ return ExeState::operator==(rhs) && eqVarToValMap(_varToItvVal, rhs._varToItvVal) &&
618
+ eqVarToValMap(_locToItvVal, rhs._locToItvVal);
619
+ }
620
+
621
+ bool operator!=(const IntervalExeState &rhs) const
622
+ {
623
+ return !(*this == rhs);
624
+ }
625
+
626
+ bool operator<(const IntervalExeState &rhs) const
627
+ {
628
+ return !(*this >= rhs);
629
+ }
630
+
631
+
632
+ bool operator>=(const IntervalExeState &rhs) const
633
+ {
634
+ return geqVarToValMap(_varToItvVal, rhs.getVarToVal()) && geqVarToValMap(_locToItvVal, rhs._locToItvVal);
635
+ }
636
+ };
465
637
  }
466
638
 
467
639
  template<>
@@ -41,20 +41,20 @@ public:
41
41
  RelationSolver() = default;
42
42
 
43
43
  /* gamma_hat, beta and abstract_consequence works on
44
- IntervalExeState (the last element of inputs) for RSY or bilateral solver */
44
+ IntervalESBase (the last element of inputs) for RSY or bilateral solver */
45
45
 
46
46
  /// Return Z3Expr according to valToValMap
47
- Z3Expr gamma_hat(const IntervalExeState &exeState) const;
47
+ Z3Expr gamma_hat(const IntervalESBase &exeState) const;
48
48
 
49
49
  /// Return Z3Expr according to another valToValMap
50
- Z3Expr gamma_hat(const IntervalExeState &alpha, const IntervalExeState &exeState) const;
50
+ Z3Expr gamma_hat(const IntervalESBase &alpha, const IntervalESBase &exeState) const;
51
51
 
52
52
  /// Return Z3Expr from a NodeID
53
- Z3Expr gamma_hat(u32_t id, const IntervalExeState &exeState) const;
53
+ Z3Expr gamma_hat(u32_t id, const IntervalESBase &exeState) const;
54
54
 
55
- IntervalExeState abstract_consequence(const IntervalExeState &lower, const IntervalExeState &upper, const IntervalExeState &domain) const;
55
+ IntervalESBase abstract_consequence(const IntervalESBase &lower, const IntervalESBase &upper, const IntervalESBase &domain) const;
56
56
 
57
- IntervalExeState beta(const Map<u32_t, double> &sigma, const IntervalExeState &exeState) const;
57
+ IntervalESBase beta(const Map<u32_t, double> &sigma, const IntervalESBase &exeState) const;
58
58
 
59
59
 
60
60
  /// Return Z3 expression lazily based on SVFVar ID
@@ -65,13 +65,13 @@ public:
65
65
 
66
66
  /* two optional solvers: RSY and bilateral */
67
67
 
68
- IntervalExeState bilateral(const IntervalExeState& domain, const Z3Expr &phi, u32_t descend_check = 0);
68
+ IntervalESBase bilateral(const IntervalESBase& domain, const Z3Expr &phi, u32_t descend_check = 0);
69
69
 
70
- IntervalExeState RSY(const IntervalExeState& domain, const Z3Expr &phi);
70
+ IntervalESBase RSY(const IntervalESBase& domain, const Z3Expr &phi);
71
71
 
72
72
  Map<u32_t, NumericLiteral> BoxedOptSolver(const Z3Expr& phi, Map<u32_t, NumericLiteral>& ret, Map<u32_t, NumericLiteral>& low_values, Map<u32_t, NumericLiteral>& high_values);
73
73
 
74
- IntervalExeState BS(const IntervalExeState& domain, const Z3Expr &phi);
74
+ IntervalESBase BS(const IntervalESBase& domain, const Z3Expr &phi);
75
75
 
76
76
  void updateMap(Map<u32_t, NumericLiteral>& map, u32_t key, const NumericLiteral& value);
77
77