forked from runtimeverification/verified-smart-contracts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
evm.smt2
24 lines (18 loc) · 734 Bytes
/
evm.smt2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
; (set-option :auto-config false)
; (set-option :smt.mbqi false)
; (set-option :smt.array.extensional false)
; int extra
(define-fun int_max ((x Int) (y Int)) Int (ite (< x y) y x))
(define-fun int_min ((x Int) (y Int)) Int (ite (< x y) x y))
(define-fun int_abs ((x Int)) Int (ite (< x 0) (- 0 x) x))
; bool to int
(define-fun smt_bool2int ((b Bool)) Int (ite b 1 0))
; IMap
(define-sort IMap () (Array Int Int))
(define-fun emptyIMap () IMap ((as const IMap) 0))
; ceil32
(define-fun ceil32 ((x Int)) Int ( * ( div ( + x 31 ) 32 ) 32 ) )
; 0 <=Int select(M, K)
;(assert (forall ((m Map) (k Int)) (<= 0 (selectInt m k))))
; (declare-fun gas ((x Int)) Int)
; (assert (forall ((i Int) (j Int)) (=> (i > j) (< (gas i) (gas j)))))