Semantics of the instructions with the
We set the error flag for
Function:
(defun exec32-store (funct rs1 rs2 imm stat) (declare (xargs :guard (and (store-funct-p funct) (ubyte5p rs1) (ubyte5p rs2) (ubyte12p imm) (state32p stat)))) (let ((__function__ 'exec32-store)) (declare (ignorable __function__)) (store-funct-case funct :sb (exec32-sb rs1 rs2 imm stat) :sh (exec32-sh rs1 rs2 imm stat) :sw (exec32-sw rs1 rs2 imm stat) :sd (error32 stat))))
Theorem:
(defthm state32p-of-exec32-store (b* ((new-stat (exec32-store funct rs1 rs2 imm stat))) (state32p new-stat)) :rule-classes :rewrite)
Theorem:
(defthm exec32-store-of-store-funct-fix-funct (equal (exec32-store (store-funct-fix funct) rs1 rs2 imm stat) (exec32-store funct rs1 rs2 imm stat)))
Theorem:
(defthm exec32-store-store-funct-equiv-congruence-on-funct (implies (store-funct-equiv funct funct-equiv) (equal (exec32-store funct rs1 rs2 imm stat) (exec32-store funct-equiv rs1 rs2 imm stat))) :rule-classes :congruence)
Theorem:
(defthm exec32-store-of-ubyte5-fix-rs1 (equal (exec32-store funct (ubyte5-fix rs1) rs2 imm stat) (exec32-store funct rs1 rs2 imm stat)))
Theorem:
(defthm exec32-store-ubyte5-equiv-congruence-on-rs1 (implies (ubyte5-equiv rs1 rs1-equiv) (equal (exec32-store funct rs1 rs2 imm stat) (exec32-store funct rs1-equiv rs2 imm stat))) :rule-classes :congruence)
Theorem:
(defthm exec32-store-of-ubyte5-fix-rs2 (equal (exec32-store funct rs1 (ubyte5-fix rs2) imm stat) (exec32-store funct rs1 rs2 imm stat)))
Theorem:
(defthm exec32-store-ubyte5-equiv-congruence-on-rs2 (implies (ubyte5-equiv rs2 rs2-equiv) (equal (exec32-store funct rs1 rs2 imm stat) (exec32-store funct rs1 rs2-equiv imm stat))) :rule-classes :congruence)
Theorem:
(defthm exec32-store-of-ubyte12-fix-imm (equal (exec32-store funct rs1 rs2 (ubyte12-fix imm) stat) (exec32-store funct rs1 rs2 imm stat)))
Theorem:
(defthm exec32-store-ubyte12-equiv-congruence-on-imm (implies (acl2::ubyte12-equiv imm imm-equiv) (equal (exec32-store funct rs1 rs2 imm stat) (exec32-store funct rs1 rs2 imm-equiv stat))) :rule-classes :congruence)
Theorem:
(defthm exec32-store-of-state32-fix-stat (equal (exec32-store funct rs1 rs2 imm (state32-fix stat)) (exec32-store funct rs1 rs2 imm stat)))
Theorem:
(defthm exec32-store-state32-equiv-congruence-on-stat (implies (state32-equiv stat stat-equiv) (equal (exec32-store funct rs1 rs2 imm stat) (exec32-store funct rs1 rs2 imm stat-equiv))) :rule-classes :congruence)