+ (combine-and-store A-ptr B-ptr modifier name
+ (lambda (x y) (addr+ x (- y))))
+ (list (addr+ ptr 1)))
+ ((MUL)
+ (combine-and-store A-ptr B-ptr modifier name
+ (lambda (x y) (modulo (* (addr+ x core-size)
+ (addr+ y core-size))
+ core-size)))
+ (list (addr+ ptr 1)))
+ ((DIV)
+ (condition-case
+ (begin
+ (combine-and-store A-ptr B-ptr modifier name
+ (lambda (x y) (quotient (addr x core-size)
+ (addr y core-size))))
+ (list (addr+ ptr 1)))
+ ((exn arithmetic) '())))
+ ((MOD)
+ (condition-case
+ (begin
+ (combine-and-store A-ptr B-ptr modifier name
+ (lambda (x y) (remainder (addr x core-size)
+ (addr y core-size))))
+ (list (addr+ ptr 1)))
+ ((exn arithmetic) '())))
+ ((JMP)
+ (list (addr+ ptr ((core-get A-ptr) 'A-num))))
+ ((JMZ)
+ (list (addr+ ptr
+ (if (case modifier
+ ((A BA)
+ (= 0 ((core-get A-ptr) 'A-num)))
+ ((B AB)
+ (= 0 ((core-get A-ptr) 'B-num)))
+ ((X I F)
+ (and (= 0 ((core-get A-ptr) 'A-num))
+ (= 0 ((core-get A-ptr) 'B-num)))))
+ ((core-get A-ptr) 'A-num)
+ 1))))
+ ((JMN)
+ (list (addr+ ptr
+ (if (not (case modifier
+ ((A BA)
+ (= 0 ((core-get A-ptr) 'A-num)))
+ ((B AB)
+ (= 0 ((core-get A-ptr) 'B-num)))
+ ((X I F)
+ (and (= 0 ((core-get A-ptr) 'A-num))
+ (= 0 ((core-get A-ptr) 'B-num))))))
+ ((core-get A-ptr) 'A-num)
+ 1))))