7d791359cabab6304ad3a7dd0e26eeaf5eeafc4a
5 print('usage: {} maxjobstart'.format(sys
.argv
[0]))
8 maxjobstart
= sys
.argv
[1]
22 print('(benchmark a4.smt')
23 print(':logic QF_UFLIA')
28 print('(j{} Int)'.format(i
), end
=' ')
34 # Make sure the times are positive and within the bound
35 print('(> j{0} 0) (<= (+ j{0} {0}) {1})'.format(i
, maxjobstart
))
36 # Make sure the dependencies are done when a task is scheduled
37 for k
in pi
.get(i
, {}):
38 print('(>= j{0} (+ j{1} {1}))'.format(i
, k
))
39 # Make sure the shared resources are not used by two tasks at once
43 print('(or (>= j{0} (+ j{1} {1}))'.format(i
, k
), end
=' ')
44 print('(<= (+ j{0} {0}) j{1}))'.format(i
, k
))
46 # Close the and,benchmark parenthesis