Commit Graph

10 Commits

Author SHA1 Message Date
d1m0
66da171050 Fix for #141 (#142)
* Add Atom and Literal base classes to CDSL Ast. Change substitution() and copy() on Def/Apply/Rtl to support substituting Var->Union[Var, Literal]. Check in Apply() constructor kinds of passed in Literals respect instruction signature

* Change verify_semantics to check all possible instantiations of enumerated immediates (needed to descrive icmp). Add all bitvector comparison primitives and bvite; Change set_semantics to optionally accept XForms; Add semantics for icmp; Fix typing errors in semantics/{smtlib, elaborate, __init__}.py after the change of VarMap->VarAtomMap

* Forgot macros.py

* Nit obscured by testing with mypy enabled present.

* Typo
2017-08-14 20:19:47 -07:00
Dimo
ede02e0f97 Cleanup, typechecking and documentation nits 2017-07-28 10:47:08 -07:00
Dimo
1ddee38895 cleanup_semantics() should remove repeated prim_from_bv(x) 2017-07-28 10:47:08 -07:00
Dimo
11014ec544 Nit: Make elaborate return a new Rtl instead of modifying the existing rtl inplace 2017-07-28 10:47:08 -07:00
Dimo
ef4ca676a4 Move apply() -> Xform.apply(); is_concrete_rtl() -> Rtl.is_concrete(); cleanup_concrete_rtl() -> Rtl.cleanup_concrete_rtl(). Documnetation nits in semantics.elaborate 2017-07-28 10:47:08 -07:00
Dimo
71f1646675 With multiple semantic transforms mentioning Enumerators, it may be possible for there not to be a substitution from the concrete rtl to some of the transforms. This is not an error - just a case where a given semantic transform doesnt apply. (e.g. icmp being described by different transforms with concrete intcc condition codes) 2017-07-28 10:47:08 -07:00
Dimo
7caaf7fea1 Fix CI: Var was only imported when mypy was present. 2017-07-24 14:08:44 -07:00
Dimo
dfb5a524b9 TI failure due to misplaced import 2017-07-24 14:08:44 -07:00
Dimo
74f72a3b43 Documentation nits; Sematnics syntax cleanup 2017-07-24 14:08:44 -07:00
Dimo
a5fe64440f Add insturction semantics. Add semantics for vsplit,vconcat,iadd. Add initial tests 2017-07-24 14:08:44 -07:00