def
mkTy
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
{φ : ℕ}
:
MLIR.AST.MLIRType φ → MLIR.AST.ExceptM (FHE q n) (FHE q n).Ty
Equations
- mkTy (MLIR.AST.MLIRType.undefined "R") = pure Ty.polynomialLike
- mkTy (MLIR.AST.MLIRType.int MLIR.AST.Signedness.Signless a) = pure Ty.integer
- mkTy MLIR.AST.MLIRType.index = pure Ty.index
- mkTy x = throw MLIR.AST.TransformError.unsupportedType
Instances For
Equations
- instTransformTy = { mkTy := mkTy }
@[irreducible, implemented_by ROfZComputable_impl]
Equations
- ROfZComputable_stuck_term q n z = ↑z
Instances For
@[simp]
def
cstComputable
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
{Γ : Ctxt (FHE q n).Ty}
(z : ℤ)
:
Expr (FHE q n) Γ EffectKind.pure Ty.polynomialLike
Equations
- cstComputable z = Expr.mk (Op.const (ROfZComputable_stuck_term q n z)) ⋯ ⋯ HVector.nil HVector.nil
Instances For
def
mkExpr
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
(Γ : Ctxt (FHE q n).Ty)
(opStx : MLIR.AST.Op 0)
:
MLIR.AST.ReaderM (FHE q n) ((eff : EffectKind) × (ty : (FHE q n).Ty) × Expr (FHE q n) Γ eff ty)
Equations
- One or more equations did not get rendered due to their size.
Instances For
instance
instTransformExprFHEOfNatNat
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
:
MLIR.AST.TransformExpr (FHE q n) 0
Equations
- instTransformExprFHEOfNatNat = { mkExpr := mkExpr }
def
mkReturn
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
(Γ : Ctxt (FHE q n).Ty)
(opStx : MLIR.AST.Op 0)
:
MLIR.AST.ReaderM (FHE q n) ((eff : EffectKind) × (ty : (FHE q n).Ty) × Com (FHE q n) Γ eff ty)
Equations
- One or more equations did not get rendered due to their size.
Instances For
instance
instTransformReturnFHEOfNatNat
{q : ℕ}
{n : ℕ}
[Fact (q > 1)]
:
MLIR.AST.TransformReturn (FHE q n) 0
Equations
- instTransformReturnFHEOfNatNat = { mkReturn := mkReturn }
Equations
- One or more equations did not get rendered due to their size.