Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion SSA/Projects/LLVMRiscV/PeepholeRefine.lean
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ structure LLVMPeepholeRewriteRefine (w : Nat) (Γ : List Ty) where
PoisonOr.IsRefinedBy (lhs.denote V |>.getN 0) (rhs.denote V |>.getN 0) := by
simp_lowering <;> bv_decide

axiom refinement_correctness {p: Prop} : p

/-- `LLVMToRiscvPeepholeRewriteRefine.toPeepholeUNSOUND` is a wrapper to pass the rewrites to the
Peephole Rewriter, with a `sorry` replacing the correctness proof which cannot be provided,
given that we are working with refinement semantics. -/
Expand All @@ -40,7 +42,7 @@ def LLVMToRiscvPeepholeRewriteRefine.toPeepholeUNSOUND
{
lhs := self.lhs
rhs := self.rhs
correct := by sorry
correct := refinement_correctness
}

@[simp_riscv] lemma toType_bv : TyDenote.toType (Ty.riscv (.bv)) = BitVec 64 := rfl
Expand Down
Loading