file_name
stringlengths
5
52
name
stringlengths
4
95
original_source_type
stringlengths
0
23k
source_type
stringlengths
9
23k
source_definition
stringlengths
9
57.9k
source
dict
source_range
dict
file_context
stringlengths
0
721k
dependencies
dict
opens_and_abbrevs
listlengths
2
94
vconfig
dict
interleaved
bool
1 class
verbose_type
stringlengths
1
7.42k
effect
stringclasses
118 values
effect_flags
listlengths
0
2
mutual_with
listlengths
0
11
ideal_premises
listlengths
0
236
proof_features
listlengths
0
1
is_simple_lemma
bool
2 classes
is_div
bool
2 classes
is_proof
bool
2 classes
is_simply_typed
bool
2 classes
is_type
bool
2 classes
partial_definition
stringlengths
5
3.99k
completed_definiton
stringlengths
1
1.63M
isa_cross_project_example
bool
1 class
Vale.AES.PPC64LE.GCTR.fst
Vale.AES.PPC64LE.GCTR.va_lemma_Gctr_blocks128
val va_lemma_Gctr_blocks128 : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_Gctr_blocks128 alg) va_s0 /\ va_get_ok va_s0 /\ ((Vale....
val va_lemma_Gctr_blocks128 : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_Gctr_blocks128 alg) va_s0 /\ va_get_ok va_s0 /\ ((Vale....
let va_lemma_Gctr_blocks128 va_b0 va_s0 alg in_b out_b key round_keys keys_b = let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod...
{ "file_name": "obj/Vale.AES.PPC64LE.GCTR.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 16, "end_line": 3030, "start_col": 0, "start_line": 2994 }
module Vale.AES.PPC64LE.GCTR open Vale.Def.Prop_s open Vale.Def.Opaque_s open Vale.Def.Words_s open Vale.Def.Types_s open Vale.Arch.Types open Vale.Arch.HeapImpl open FStar.Seq open Vale.AES.AES_BE_s open Vale.AES.PPC64LE.AES open Vale.AES.GCTR_BE_s open Vale.AES.GCTR_BE open Vale.AES.GCM_helpers_BE open Vale.Poly1305....
{ "checked_file": "/", "dependencies": [ "Vale.PPC64LE.State.fsti.checked", "Vale.PPC64LE.QuickCodes.fsti.checked", "Vale.PPC64LE.QuickCode.fst.checked", "Vale.PPC64LE.Memory.fsti.checked", "Vale.PPC64LE.Machine_s.fst.checked", "Vale.PPC64LE.InsVector.fsti.checked", "Vale.PPC64LE.InsStac...
[ { "abbrev": false, "full_module": "Vale.Lib.Basic", "short_module": null }, { "abbrev": false, "full_module": "Vale.AES.Types_helpers", "short_module": null }, { "abbrev": false, "full_module": "Vale.PPC64LE.QuickCodes", "short_module": null }, { "abbrev": false, ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
va_b0: Vale.PPC64LE.Decls.va_code -> va_s0: Vale.PPC64LE.Decls.va_state -> alg: Vale.AES.AES_common_s.algorithm -> in_b: Vale.PPC64LE.Memory.buffer128 -> out_b: Vale.PPC64LE.Memory.buffer128 -> key: FStar.Seq.Base.seq Vale.PPC64LE.Memory.nat32 -> round_keys: FStar.Seq.Base.seq Vale.PPC64LE....
Prims.Ghost
[]
[]
[ "Vale.PPC64LE.Decls.va_code", "Vale.PPC64LE.Decls.va_state", "Vale.AES.AES_common_s.algorithm", "Vale.PPC64LE.Memory.buffer128", "FStar.Seq.Base.seq", "Vale.PPC64LE.Memory.nat32", "Vale.PPC64LE.Memory.quad32", "Vale.PPC64LE.QuickCodes.fuel", "Prims.unit", "FStar.Pervasives.Native.Mktuple2", "Val...
[]
false
false
false
false
false
let va_lemma_Gctr_blocks128 va_b0 va_s0 alg in_b out_b key round_keys keys_b =
let va_mods:va_mods_t = [ va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3...
false
Vale.AES.GF128.fst
Vale.AES.GF128.lemma_Mul128
val lemma_Mul128 (a b:poly) : Lemma (requires degree a < 128 /\ degree b < 128) (ensures ( let aL = mask a 64 in let bL = mask b 64 in let aH = shift a (-64) in let bH = shift b (-64) in a *. b == aL *. bL +. shift (aL *. bH +. aH *. bL) 64 +. shift (aH *. bH) 128 ))
val lemma_Mul128 (a b:poly) : Lemma (requires degree a < 128 /\ degree b < 128) (ensures ( let aL = mask a 64 in let bL = mask b 64 in let aH = shift a (-64) in let bH = shift b (-64) in a *. b == aL *. bL +. shift (aL *. bH +. aH *. bL) 64 +. shift (aH *. bH) 128 ))
let lemma_Mul128 a b = let aL = mask a 64 in let bL = mask b 64 in let aH = shift a (-64) in let bH = shift b (-64) in calc (==) { a *. b; == { lemma_bitwise_all (); lemma_equal a (aL +. shift aH 64); lemma_equal b (bL +. shift bH 64) } (aL +. shift aH 64) *. (bL +. shift bH ...
{ "file_name": "vale/code/crypto/aes/Vale.AES.GF128.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 804, "start_col": 0, "start_line": 773 }
module Vale.AES.GF128 open FStar.Mul open Vale.Arch.TypesNative open Vale.Math.Poly2.Bits #reset-options "--z3rlimit 20" let lemma_shift_left_1 a = reveal_to_quad32 a; reveal_to_quad32 (shift a 1); lemma_zero_nth 32; lemma_ishl_nth_all 32; lemma_ishr_nth_all 32; lemma_ixor_nth_all 32; lemma_index_all ();...
{ "checked_file": "/", "dependencies": [ "Vale.Math.Poly2.Bits.fsti.checked", "Vale.Arch.TypesNative.fsti.checked", "Vale.Arch.Types.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": true, "s...
[ { "abbrev": false, "full_module": "Vale.Math.Poly2.Bits", "short_module": null }, { "abbrev": false, "full_module": "Vale.Arch.TypesNative", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Vale.Math.Poly2_s.poly -> b: Vale.Math.Poly2_s.poly -> FStar.Pervasives.Lemma (requires Vale.Math.Poly2_s.degree a < 128 /\ Vale.Math.Poly2_s.degree b < 128) (ensures (let aL = Vale.Math.Poly2.mask a 64 in let bL = Vale.Math.Poly2.mask b 64 in let aH = Vale.Math.Poly2_s.shif...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Vale.Math.Poly2_s.poly", "FStar.Calc.calc_finish", "Prims.eq2", "Vale.Math.Poly2.op_Star_Dot", "Vale.Math.Poly2.op_Plus_Dot", "Vale.Math.Poly2_s.shift", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "Vale.Math.Poly2_s.monomial", "FStar.Calc.calc...
[]
false
false
true
false
false
let lemma_Mul128 a b =
let aL = mask a 64 in let bL = mask b 64 in let aH = shift a (- 64) in let bH = shift b (- 64) in calc ( == ) { a *. b; ( == ) { (lemma_bitwise_all (); lemma_equal a (aL +. shift aH 64); lemma_equal b (bL +. shift bH 64)) } (aL +. shift aH 64) *. (bL +. shift bH 64); ( == ) { lemma_mul_distribute_left a...
false
Hacl.Bignum32.fst
Hacl.Bignum32.mont_ctx_free
val mont_ctx_free: MA.bn_field_free_st t_limbs
val mont_ctx_free: MA.bn_field_free_st t_limbs
let mont_ctx_free k = MA.bn_field_free k
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 20, "end_line": 61, "start_col": 0, "start_line": 60 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Hacl.Bignum.MontArithmetic.bn_field_free_st Hacl.Bignum32.t_limbs
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.MontArithmetic.pbn_mont_ctx", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.MontArithmetic.bn_field_free", "Prims.unit" ]
[]
false
false
false
true
false
let mont_ctx_free k =
MA.bn_field_free k
false
Vale.AES.GF128.fst
Vale.AES.GF128.lemma_mul_odd_reverse_shift_right_lo_shift
val lemma_mul_odd_reverse_shift_right_lo_shift (a h:poly) (n:pos) : Lemma (requires degree h < n /\ degree a < n /\ h.[0]) (ensures ( let n1 = n - 1 in let m = monomial n in reverse (((a *. h) %. m) *. m) (n + n - 1) == reverse a n1 +. (reverse a n1 *. reverse (shift h (-1)) n1) /. m ))
val lemma_mul_odd_reverse_shift_right_lo_shift (a h:poly) (n:pos) : Lemma (requires degree h < n /\ degree a < n /\ h.[0]) (ensures ( let n1 = n - 1 in let m = monomial n in reverse (((a *. h) %. m) *. m) (n + n - 1) == reverse a n1 +. (reverse a n1 *. reverse (shift h (-1)) n1) /. m ))
let lemma_mul_odd_reverse_shift_right_lo_shift a h n = let n1 = n - 1 in let nn1 = n + n - 1 in let m = monomial n in let ah = a *. h in calc (==) { reverse ((ah %. m) *. m) nn1; == {lemma_shift_is_mul (ah %. m) n; lemma_mask_is_mod ah n} reverse (shift (mask ah n) n) nn1; == { lemma_bit...
{ "file_name": "vale/code/crypto/aes/Vale.AES.GF128.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 324, "start_col": 0, "start_line": 298 }
module Vale.AES.GF128 open FStar.Mul open Vale.Arch.TypesNative open Vale.Math.Poly2.Bits #reset-options "--z3rlimit 20" let lemma_shift_left_1 a = reveal_to_quad32 a; reveal_to_quad32 (shift a 1); lemma_zero_nth 32; lemma_ishl_nth_all 32; lemma_ishr_nth_all 32; lemma_ixor_nth_all 32; lemma_index_all ();...
{ "checked_file": "/", "dependencies": [ "Vale.Math.Poly2.Bits.fsti.checked", "Vale.Arch.TypesNative.fsti.checked", "Vale.Arch.Types.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": true, "s...
[ { "abbrev": false, "full_module": "Vale.Math.Poly2.Bits", "short_module": null }, { "abbrev": false, "full_module": "Vale.Arch.TypesNative", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Vale.Math.Poly2_s.poly -> h: Vale.Math.Poly2_s.poly -> n: Prims.pos -> FStar.Pervasives.Lemma (requires Vale.Math.Poly2_s.degree h < n /\ Vale.Math.Poly2_s.degree a < n /\ h.[ 0 ]) (ensures (let n1 = n - 1 in let m = Vale.Math.Poly2_s.monomial n in Vale.Math.Poly2_s.reverse ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Vale.Math.Poly2_s.poly", "Prims.pos", "FStar.Calc.calc_finish", "Prims.eq2", "Vale.Math.Poly2_s.reverse", "Vale.Math.Poly2.op_Star_Dot", "Vale.Math.Poly2.op_Percent_Dot", "Vale.Math.Poly2.op_Plus_Dot", "Vale.Math.Poly2.op_Slash_Dot", "Vale.Math.Poly2_s.shift", "Prims.op_Minus", "Prims.Cons", ...
[]
false
false
true
false
false
let lemma_mul_odd_reverse_shift_right_lo_shift a h n =
let n1 = n - 1 in let nn1 = n + n - 1 in let m = monomial n in let ah = a *. h in calc ( == ) { reverse ((ah %. m) *. m) nn1; ( == ) { (lemma_shift_is_mul (ah %. m) n; lemma_mask_is_mod ah n) } reverse (shift (mask ah n) n) nn1; ( == ) { (lemma_bitwise_all (); lemma_equal (reverse (shift (mask ah n) n) ...
false
Hacl.Bignum32.fst
Hacl.Bignum32.lt_mask
val lt_mask: len:_ -> BN.bn_lt_mask_st t_limbs len
val lt_mask: len:_ -> BN.bn_lt_mask_st t_limbs len
let lt_mask len a b = BN.bn_lt_mask len a b
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 23, "end_line": 93, "start_col": 0, "start_line": 92 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Lib.IntTypes.size_t -> Hacl.Bignum.bn_lt_mask_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Lib.IntTypes.size_t", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.bn_lt_mask", "Hacl.Bignum.Definitions.limb" ]
[]
false
false
false
false
false
let lt_mask len a b =
BN.bn_lt_mask len a b
false
Hacl.Bignum32.fst
Hacl.Bignum32.new_bn_from_bytes_be
val new_bn_from_bytes_be: BS.new_bn_from_bytes_be_st t_limbs
val new_bn_from_bytes_be: BS.new_bn_from_bytes_be_st t_limbs
let new_bn_from_bytes_be r len b = BS.new_bn_from_bytes_be r len b
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 33, "end_line": 81, "start_col": 0, "start_line": 80 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Hacl.Bignum.SafeAPI.new_bn_from_bytes_be_st Hacl.Bignum32.t_limbs
Prims.Tot
[ "total" ]
[]
[ "FStar.Monotonic.HyperHeap.rid", "Lib.IntTypes.size_t", "Lib.Buffer.lbuffer", "Lib.IntTypes.uint8", "Hacl.Bignum.SafeAPI.new_bn_from_bytes_be", "Hacl.Bignum32.t_limbs", "LowStar.Buffer.buffer", "Hacl.Bignum.Definitions.limb" ]
[]
false
false
false
true
false
let new_bn_from_bytes_be r len b =
BS.new_bn_from_bytes_be r len b
false
Hacl.Bignum32.fst
Hacl.Bignum32.eq_mask
val eq_mask: len:_ -> BN.bn_eq_mask_st t_limbs len
val eq_mask: len:_ -> BN.bn_eq_mask_st t_limbs len
let eq_mask len a b = BN.bn_eq_mask len a b
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 23, "end_line": 96, "start_col": 0, "start_line": 95 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Lib.IntTypes.size_t -> Hacl.Bignum.bn_eq_mask_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Lib.IntTypes.size_t", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.bn_eq_mask", "Hacl.Bignum.Definitions.limb" ]
[]
false
false
false
false
false
let eq_mask len a b =
BN.bn_eq_mask len a b
false
Hacl.Bignum32.fst
Hacl.Bignum32.new_bn_from_bytes_le
val new_bn_from_bytes_le: BS.new_bn_from_bytes_le_st t_limbs
val new_bn_from_bytes_le: BS.new_bn_from_bytes_le_st t_limbs
let new_bn_from_bytes_le r len b = BS.new_bn_from_bytes_le r len b
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 33, "end_line": 84, "start_col": 0, "start_line": 83 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Hacl.Bignum.SafeAPI.new_bn_from_bytes_le_st Hacl.Bignum32.t_limbs
Prims.Tot
[ "total" ]
[]
[ "FStar.Monotonic.HyperHeap.rid", "Lib.IntTypes.size_t", "Lib.Buffer.lbuffer", "Lib.IntTypes.uint8", "Hacl.Bignum.SafeAPI.new_bn_from_bytes_le", "Hacl.Bignum32.t_limbs", "LowStar.Buffer.buffer", "Hacl.Bignum.Definitions.limb" ]
[]
false
false
false
true
false
let new_bn_from_bytes_le r len b =
BS.new_bn_from_bytes_le r len b
false
Vale.AES.PPC64LE.GCTR.fst
Vale.AES.PPC64LE.GCTR.va_lemma_Gctr_blocks128_6way
val va_lemma_Gctr_blocks128_6way : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_Gctr_blocks128_6way alg) va_s0 /\ va_get_ok va_s0 /\...
val va_lemma_Gctr_blocks128_6way : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_Gctr_blocks128_6way alg) va_s0 /\ va_get_ok va_s0 /\...
let va_lemma_Gctr_blocks128_6way va_b0 va_s0 alg in_b out_b key round_keys keys_b = let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; v...
{ "file_name": "obj/Vale.AES.PPC64LE.GCTR.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 16, "end_line": 2692, "start_col": 0, "start_line": 2648 }
module Vale.AES.PPC64LE.GCTR open Vale.Def.Prop_s open Vale.Def.Opaque_s open Vale.Def.Words_s open Vale.Def.Types_s open Vale.Arch.Types open Vale.Arch.HeapImpl open FStar.Seq open Vale.AES.AES_BE_s open Vale.AES.PPC64LE.AES open Vale.AES.GCTR_BE_s open Vale.AES.GCTR_BE open Vale.AES.GCM_helpers_BE open Vale.Poly1305....
{ "checked_file": "/", "dependencies": [ "Vale.PPC64LE.State.fsti.checked", "Vale.PPC64LE.QuickCodes.fsti.checked", "Vale.PPC64LE.QuickCode.fst.checked", "Vale.PPC64LE.Memory.fsti.checked", "Vale.PPC64LE.Machine_s.fst.checked", "Vale.PPC64LE.InsVector.fsti.checked", "Vale.PPC64LE.InsStac...
[ { "abbrev": false, "full_module": "Vale.Lib.Basic", "short_module": null }, { "abbrev": false, "full_module": "Vale.AES.Types_helpers", "short_module": null }, { "abbrev": false, "full_module": "Vale.PPC64LE.QuickCodes", "short_module": null }, { "abbrev": false, ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
va_b0: Vale.PPC64LE.Decls.va_code -> va_s0: Vale.PPC64LE.Decls.va_state -> alg: Vale.AES.AES_common_s.algorithm -> in_b: Vale.PPC64LE.Memory.buffer128 -> out_b: Vale.PPC64LE.Memory.buffer128 -> key: FStar.Seq.Base.seq Vale.PPC64LE.Memory.nat32 -> round_keys: FStar.Seq.Base.seq Vale.PPC64LE....
Prims.Ghost
[]
[]
[ "Vale.PPC64LE.Decls.va_code", "Vale.PPC64LE.Decls.va_state", "Vale.AES.AES_common_s.algorithm", "Vale.PPC64LE.Memory.buffer128", "FStar.Seq.Base.seq", "Vale.PPC64LE.Memory.nat32", "Vale.PPC64LE.Memory.quad32", "Vale.PPC64LE.QuickCodes.fuel", "Prims.unit", "FStar.Pervasives.Native.Mktuple2", "Val...
[]
false
false
false
false
false
let va_lemma_Gctr_blocks128_6way va_b0 va_s0 alg in_b out_b key round_keys keys_b =
let va_mods:va_mods_t = [ va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3...
false
Steel.Closure.fst
Steel.Closure.ctr
val ctr : r: Steel.Reference.ref Prims.int -> Type0
let ctr (r:ref int) = prev:erased int -> SteelT (y:int{y == prev + 1}) (repr r prev) (repr r)
{ "file_name": "lib/steel/Steel.Closure.fst", "git_rev": "f984200f79bdc452374ae994a5ca837496476c41", "git_url": "https://github.com/FStarLang/steel.git", "project_name": "steel" }
{ "end_col": 94, "end_line": 28, "start_col": 0, "start_line": 28 }
(* Copyright 2020 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "checked_file": "/", "dependencies": [ "Steel.Reference.fsti.checked", "Steel.Memory.fsti.checked", "Steel.FractionalPermission.fst.checked", "Steel.Effect.Atomic.fsti.checked", "Steel.Effect.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": t...
[ { "abbrev": false, "full_module": "Steel.FractionalPermission", "short_module": null }, { "abbrev": false, "full_module": "Steel.Reference", "short_module": null }, { "abbrev": false, "full_module": "Steel.Effect", "short_module": null }, { "abbrev": false, "f...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
r: Steel.Reference.ref Prims.int -> Type0
Prims.Tot
[ "total" ]
[]
[ "Steel.Reference.ref", "Prims.int", "FStar.Ghost.erased", "Prims.eq2", "Prims.op_Addition", "FStar.Ghost.reveal", "Steel.Closure.repr" ]
[]
false
false
false
true
true
let ctr (r: ref int) =
prev: erased int -> SteelT (y: int{y == prev + 1}) (repr r prev) (repr r)
false
Steel.Closure.fst
Steel.Closure.repr
val repr : r: Steel.Reference.ref Prims.int -> x: Prims.int -> Steel.Effect.Common.vprop
let repr (r:ref int) (x:int) = pts_to r full_perm (hide x)
{ "file_name": "lib/steel/Steel.Closure.fst", "git_rev": "f984200f79bdc452374ae994a5ca837496476c41", "git_url": "https://github.com/FStarLang/steel.git", "project_name": "steel" }
{ "end_col": 58, "end_line": 26, "start_col": 0, "start_line": 26 }
(* Copyright 2020 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "checked_file": "/", "dependencies": [ "Steel.Reference.fsti.checked", "Steel.Memory.fsti.checked", "Steel.FractionalPermission.fst.checked", "Steel.Effect.Atomic.fsti.checked", "Steel.Effect.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": t...
[ { "abbrev": false, "full_module": "Steel.FractionalPermission", "short_module": null }, { "abbrev": false, "full_module": "Steel.Reference", "short_module": null }, { "abbrev": false, "full_module": "Steel.Effect", "short_module": null }, { "abbrev": false, "f...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
r: Steel.Reference.ref Prims.int -> x: Prims.int -> Steel.Effect.Common.vprop
Prims.Tot
[ "total" ]
[]
[ "Steel.Reference.ref", "Prims.int", "Steel.Reference.pts_to", "Steel.FractionalPermission.full_perm", "Steel.Effect.Common.vprop" ]
[]
false
false
false
true
false
let repr (r: ref int) (x: int) =
pts_to r full_perm (hide x)
false
Hacl.Bignum32.fst
Hacl.Bignum32.add_mod
val add_mod: len:BN.meta_len t_limbs -> BN.bn_add_mod_n_st t_limbs len
val add_mod: len:BN.meta_len t_limbs -> BN.bn_add_mod_n_st t_limbs len
let add_mod len n a b res = (ke len).BE.bn.BN.add_mod_n n a b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 39, "end_line": 30, "start_col": 0, "start_line": 29 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.bn_add_mod_n_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.__proj__Mkbn__item__add_mod_n", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Prims.unit" ]
[]
false
false
false
false
false
let add_mod len n a b res =
(ke len).BE.bn.BN.add_mod_n n a b res
false
HoareSTFree.fst
HoareSTFree.act_p
val act_p (#st #a: Type) (a_p: mpre st) (a_q: mpost st a) (k_p: (a -> mpre st)) : mpre st
val act_p (#st #a: Type) (a_p: mpre st) (a_q: mpost st a) (k_p: (a -> mpre st)) : mpre st
let act_p (#st:Type) (#a:Type) (a_p:mpre st) (a_q:mpost st a) (k_p:a -> mpre st) : mpre st = fun s0 -> a_p s0 /\ (forall (x:a) (s1:st). a_q s0 x s1 ==> k_p x s1)
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 70, "end_line": 61, "start_col": 0, "start_line": 60 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a_p: HoareSTFree.mpre st -> a_q: HoareSTFree.mpost st a -> k_p: (_: a -> HoareSTFree.mpre st) -> HoareSTFree.mpre st
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpre", "HoareSTFree.mpost", "Prims.l_and", "Prims.l_Forall", "Prims.l_imp" ]
[]
false
false
false
true
false
let act_p (#st #a: Type) (a_p: mpre st) (a_q: mpost st a) (k_p: (a -> mpre st)) : mpre st =
fun s0 -> a_p s0 /\ (forall (x: a) (s1: st). a_q s0 x s1 ==> k_p x s1)
false
HoareSTFree.fst
HoareSTFree.strengthen_pre
val strengthen_pre (#st: Type) (p: mpre st) (phi: pure_pre) : mpre st
val strengthen_pre (#st: Type) (p: mpre st) (phi: pure_pre) : mpre st
let strengthen_pre (#st:Type) (p:mpre st) (phi:pure_pre) : mpre st = fun s -> p s /\ phi
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 21, "end_line": 80, "start_col": 0, "start_line": 79 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
p: HoareSTFree.mpre st -> phi: Prims.pure_pre -> HoareSTFree.mpre st
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpre", "Prims.pure_pre", "Prims.l_and" ]
[]
false
false
false
true
false
let strengthen_pre (#st: Type) (p: mpre st) (phi: pure_pre) : mpre st =
fun s -> p s /\ phi
false
HoareSTFree.fst
HoareSTFree.act_q
val act_q (#st #a #b: Type) (a_q: mpost st a) (k_q: (a -> mpost st b)) : mpost st b
val act_q (#st #a #b: Type) (a_q: mpost st a) (k_q: (a -> mpost st b)) : mpost st b
let act_q (#st:Type) (#a:Type) (#b:Type) (a_q:mpost st a) (k_q:a -> mpost st b) : mpost st b = fun s0 y s2 -> exists (x:a) (s1:st). a_q s0 x s1 /\ k_q x s1 y s2
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 67, "end_line": 65, "start_col": 0, "start_line": 64 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a_q: HoareSTFree.mpost st a -> k_q: (_: a -> HoareSTFree.mpost st b) -> HoareSTFree.mpost st b
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpost", "Prims.l_Exists", "Prims.l_and" ]
[]
false
false
false
true
false
let act_q (#st #a #b: Type) (a_q: mpost st a) (k_q: (a -> mpost st b)) : mpost st b =
fun s0 y s2 -> exists (x: a) (s1: st). a_q s0 x s1 /\ k_q x s1 y s2
false
Hacl.Bignum32.fst
Hacl.Bignum32.bn_slow_precomp
val bn_slow_precomp (len: BN.meta_len t_limbs) : BR.bn_mod_slow_precomp_st t_limbs len
val bn_slow_precomp (len: BN.meta_len t_limbs) : BR.bn_mod_slow_precomp_st t_limbs len
let bn_slow_precomp (len:BN.meta_len t_limbs) : BR.bn_mod_slow_precomp_st t_limbs len = BR.bn_mod_slow_precomp (kam len)
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 34, "end_line": 43, "start_col": 0, "start_line": 42 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.ModReduction.bn_mod_slow_precomp_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.ModReduction.bn_mod_slow_precomp", "Hacl.Bignum32.kam", "Hacl.Bignum.ModReduction.bn_mod_slow_precomp_st" ]
[]
false
false
false
false
false
let bn_slow_precomp (len: BN.meta_len t_limbs) : BR.bn_mod_slow_precomp_st t_limbs len =
BR.bn_mod_slow_precomp (kam len)
false
HoareSTFree.fst
HoareSTFree.weaken_ok
val weaken_ok (#st #a: Type) (p0: mpre st) (q0: mpost st a) (p1: mpre st) (q1: mpost st a) : Type0
val weaken_ok (#st #a: Type) (p0: mpre st) (q0: mpost st a) (p1: mpre st) (q1: mpost st a) : Type0
let weaken_ok (#st:Type) (#a:Type) (p0:mpre st) (q0:mpost st a) (p1:mpre st) (q1:mpost st a) : Type0 = (forall (s:st). p1 s ==> p0 s) /\ (forall (s0:st) (x:a) (s1:st). p1 s0 ==> q0 s0 x s1 ==> q1 s0 x s1)
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 69, "end_line": 73, "start_col": 0, "start_line": 71 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
p0: HoareSTFree.mpre st -> q0: HoareSTFree.mpost st a -> p1: HoareSTFree.mpre st -> q1: HoareSTFree.mpost st a -> Type0
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpre", "HoareSTFree.mpost", "Prims.l_and", "Prims.l_Forall", "Prims.l_imp" ]
[]
false
false
false
true
true
let weaken_ok (#st #a: Type) (p0: mpre st) (q0: mpost st a) (p1: mpre st) (q1: mpost st a) : Type0 =
(forall (s: st). p1 s ==> p0 s) /\ (forall (s0: st) (x: a) (s1: st). p1 s0 ==> q0 s0 x s1 ==> q1 s0 x s1)
false
Vale.AES.GF128.fst
Vale.AES.GF128.lemma_reduce_rev_hi
val lemma_reduce_rev_hi (x3 x2 h:poly) (n:pos) : Lemma (requires degree x3 < n /\ degree x2 < n /\ degree (monomial (n + n) +. h) == n + n /\ degree h < n /\ h.[0] ) (ensures ( let nn = n + n in let mm = monomial nn in let m = monomial n in let g = mm +. h in let c = revers...
val lemma_reduce_rev_hi (x3 x2 h:poly) (n:pos) : Lemma (requires degree x3 < n /\ degree x2 < n /\ degree (monomial (n + n) +. h) == n + n /\ degree h < n /\ h.[0] ) (ensures ( let nn = n + n in let mm = monomial nn in let m = monomial n in let g = mm +. h in let c = revers...
let lemma_reduce_rev_hi x3 x2 h n = let n1 = n - 1 in let nn = n + n in let nn1 = n + n - 1 in let mm = monomial nn in let m = monomial n in let g = mm +. h in let c = reverse (shift h (-1)) n1 in let x32 = (x3 *. m +. x2) *. mm in let y0 = reverse x3 n1 in let y1 = reverse x2 n1 in let x3h = x3 *...
{ "file_name": "vale/code/crypto/aes/Vale.AES.GF128.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 428, "start_col": 0, "start_line": 346 }
module Vale.AES.GF128 open FStar.Mul open Vale.Arch.TypesNative open Vale.Math.Poly2.Bits #reset-options "--z3rlimit 20" let lemma_shift_left_1 a = reveal_to_quad32 a; reveal_to_quad32 (shift a 1); lemma_zero_nth 32; lemma_ishl_nth_all 32; lemma_ishr_nth_all 32; lemma_ixor_nth_all 32; lemma_index_all ();...
{ "checked_file": "/", "dependencies": [ "Vale.Math.Poly2.Bits.fsti.checked", "Vale.Arch.TypesNative.fsti.checked", "Vale.Arch.Types.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": true, "s...
[ { "abbrev": false, "full_module": "Vale.Math.Poly2.Bits", "short_module": null }, { "abbrev": false, "full_module": "Vale.Arch.TypesNative", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
x3: Vale.Math.Poly2_s.poly -> x2: Vale.Math.Poly2_s.poly -> h: Vale.Math.Poly2_s.poly -> n: Prims.pos -> FStar.Pervasives.Lemma (requires Vale.Math.Poly2_s.degree x3 < n /\ Vale.Math.Poly2_s.degree x2 < n /\ Vale.Math.Poly2_s.degree (Vale.Math.Poly2_s.monomial (n + n) +. h) == n...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Vale.Math.Poly2_s.poly", "Prims.pos", "FStar.Calc.calc_finish", "Prims.eq2", "Vale.Math.Poly2_s.reverse", "Vale.Math.Poly2.op_Percent_Dot", "Vale.Math.Poly2.op_Plus_Dot", "Vale.Math.Poly2.op_Star_Dot", "Vale.Math.Poly2.mask", "Vale.Math.Poly2_s.shift", "Vale.Math.Poly2.swap", "Prims.Cons", ...
[]
false
false
true
false
false
let lemma_reduce_rev_hi x3 x2 h n =
let n1 = n - 1 in let nn = n + n in let nn1 = n + n - 1 in let mm = monomial nn in let m = monomial n in let g = mm +. h in let c = reverse (shift h (- 1)) n1 in let x32 = (x3 *. m +. x2) *. mm in let y0 = reverse x3 n1 in let y1 = reverse x2 n1 in let x3h = x3 *. h in let x3hl = x3h %. m in let x3hh = x3h /. m in lemm...
false
HoareSTFree.fst
HoareSTFree.return
val return (a: Type) (x: a) (q: post a) : repr a (fun s0 -> q s0 x s0) q
val return (a: Type) (x: a) (q: post a) : repr a (fun s0 -> q s0 x s0) q
let return (a:Type) (x:a) (q:post a) : repr a (fun s0 -> q s0 x s0) q = fun _ -> Ret x
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 16, "end_line": 131, "start_col": 0, "start_line": 130 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> x: a -> q: HoareSTFree.post a -> HoareSTFree.repr a (fun s0 -> q s0 x s0) q
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.post", "Prims.unit", "HoareSTFree.Ret", "HoareSTFree.st", "HoareSTFree.m", "HoareSTFree.repr" ]
[]
false
false
false
false
false
let return (a: Type) (x: a) (q: post a) : repr a (fun s0 -> q s0 x s0) q =
fun _ -> Ret x
false
Hacl.Bignum32.fst
Hacl.Bignum32.add
val add: len:BN.meta_len t_limbs -> BN.bn_add_eq_len_st t_limbs len
val add: len:BN.meta_len t_limbs -> BN.bn_add_eq_len_st t_limbs len
let add len a b res = (ke len).BE.bn.BN.add a b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 31, "end_line": 24, "start_col": 0, "start_line": 23 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.bn_add_eq_len_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.__proj__Mkbn__item__add", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Hacl.Spec.Bignum.Base.carry" ]
[]
false
false
false
false
false
let add len a b res =
(ke len).BE.bn.BN.add a b res
false
Hacl.Bignum32.fst
Hacl.Bignum32.mont_ctx_init
val mont_ctx_init: len:BN.meta_len t_limbs -> MA.bn_field_init_st t_limbs len
val mont_ctx_init: len:BN.meta_len t_limbs -> MA.bn_field_init_st t_limbs len
let mont_ctx_init len r n = MA.bn_field_init len (ke len).BE.precompr2 r n
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 48, "end_line": 58, "start_col": 0, "start_line": 57 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.MontArithmetic.bn_field_init_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "FStar.Monotonic.HyperHeap.rid", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.MontArithmetic.bn_field_init", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__precompr2", "Hacl.Bignum32.ke", "Hacl.Bignum.MontArithmetic.pbn_mont_ctx" ]
[]
false
false
false
false
false
let mont_ctx_init len r n =
MA.bn_field_init len (ke len).BE.precompr2 r n
false
Hacl.Bignum32.fst
Hacl.Bignum32.sub
val sub: len:BN.meta_len t_limbs -> BN.bn_sub_eq_len_st t_limbs len
val sub: len:BN.meta_len t_limbs -> BN.bn_sub_eq_len_st t_limbs len
let sub len a b res = (ke len).BE.bn.BN.sub a b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 31, "end_line": 27, "start_col": 0, "start_line": 26 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.bn_sub_eq_len_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.__proj__Mkbn__item__sub", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Hacl.Spec.Bignum.Base.carry" ]
[]
false
false
false
false
false
let sub len a b res =
(ke len).BE.bn.BN.sub a b res
false
HoareSTFree.fst
HoareSTFree.pure_p
val pure_p (#a: Type) (wp: pure_wp a) : pre
val pure_p (#a: Type) (wp: pure_wp a) : pre
let pure_p (#a:Type) (wp:pure_wp a) : pre = fun _ -> as_requires wp
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 25, "end_line": 181, "start_col": 0, "start_line": 180 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
wp: Prims.pure_wp a -> HoareSTFree.pre
Prims.Tot
[ "total" ]
[]
[ "Prims.pure_wp", "HoareSTFree.st", "Prims.as_requires", "HoareSTFree.pre" ]
[]
false
false
false
true
false
let pure_p (#a: Type) (wp: pure_wp a) : pre =
fun _ -> as_requires wp
false
HoareSTFree.fst
HoareSTFree.weaker_p
val weaker_p : p0: HoareSTFree.mpre st -> p1: HoareSTFree.mpre st -> s0: st -> s1: st -> Prims.logical
let weaker_p (#st:Type) (p0 p1:mpre st) (s0 s1:st) = p0 s0 ==> p1 s1
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 68, "end_line": 242, "start_col": 0, "start_line": 242 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
p0: HoareSTFree.mpre st -> p1: HoareSTFree.mpre st -> s0: st -> s1: st -> Prims.logical
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpre", "Prims.l_imp", "Prims.logical" ]
[]
false
false
false
true
true
let weaker_p (#st: Type) (p0 p1: mpre st) (s0 s1: st) =
p0 s0 ==> p1 s1
false
Hacl.Bignum32.fst
Hacl.Bignum32.sub_mod
val sub_mod: len:BN.meta_len t_limbs -> BN.bn_sub_mod_n_st t_limbs len
val sub_mod: len:BN.meta_len t_limbs -> BN.bn_sub_mod_n_st t_limbs len
let sub_mod len n a b res = (ke len).BE.bn.BN.sub_mod_n n a b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 39, "end_line": 33, "start_col": 0, "start_line": 32 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.bn_sub_mod_n_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.__proj__Mkbn__item__sub_mod_n", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Prims.unit" ]
[]
false
false
false
false
false
let sub_mod len n a b res =
(ke len).BE.bn.BN.sub_mod_n n a b res
false
HoareSTFree.fst
HoareSTFree.pure_q
val pure_q (#a: Type) (wp: pure_wp a) : post a
val pure_q (#a: Type) (wp: pure_wp a) : post a
let pure_q (#a:Type) (wp:pure_wp a) : post a = fun s0 x s1 -> s0 == s1 /\ as_ensures wp x
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 44, "end_line": 185, "start_col": 0, "start_line": 184 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
wp: Prims.pure_wp a -> HoareSTFree.post a
Prims.Tot
[ "total" ]
[]
[ "Prims.pure_wp", "HoareSTFree.st", "Prims.l_and", "Prims.eq2", "Prims.as_ensures", "HoareSTFree.post" ]
[]
false
false
false
true
false
let pure_q (#a: Type) (wp: pure_wp a) : post a =
fun s0 x s1 -> s0 == s1 /\ as_ensures wp x
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_inv_prime_vartime
val mod_inv_prime_vartime: len:BN.meta_len t_limbs -> BS.bn_mod_inv_prime_safe_st t_limbs len
val mod_inv_prime_vartime: len:BN.meta_len t_limbs -> BS.bn_mod_inv_prime_safe_st t_limbs len
let mod_inv_prime_vartime len n a res = BS.mk_bn_mod_inv_prime_safe len (ke len).BE.exp_vt n a res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 60, "end_line": 55, "start_col": 0, "start_line": 54 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.SafeAPI.bn_mod_inv_prime_safe_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Hacl.Bignum.SafeAPI.mk_bn_mod_inv_prime_safe", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__exp_vt", "Hacl.Bignum32.ke", "Prims.bool" ]
[]
false
false
false
false
false
let mod_inv_prime_vartime len n a res =
BS.mk_bn_mod_inv_prime_safe len (ke len).BE.exp_vt n a res
false
HoareSTFree.fst
HoareSTFree.stronger_q
val stronger_q : q0: HoareSTFree.mpost st a -> q1: HoareSTFree.mpost st a -> s0: st -> s1: st -> Prims.logical
let stronger_q (#st:Type) (#a:Type) (q0 q1:mpost st a) (s0 s1:st) = forall (x:a) (s_final:st). q1 s1 x s_final ==> q0 s0 x s_final
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 64, "end_line": 246, "start_col": 0, "start_line": 245 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
q0: HoareSTFree.mpost st a -> q1: HoareSTFree.mpost st a -> s0: st -> s1: st -> Prims.logical
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.mpost", "Prims.l_Forall", "Prims.l_imp", "Prims.logical" ]
[]
false
false
false
true
true
let stronger_q (#st #a: Type) (q0 q1: mpost st a) (s0 s1: st) =
forall (x: a) (s_final: st). q1 s1 x s_final ==> q0 s0 x s_final
false
HoareSTFree.fst
HoareSTFree.subcomp
val subcomp (a: Type) (f_p: pre) (f_q: post a) (g_p: pre) (g_q: post a) (f: repr a f_p f_q) : Pure (repr a g_p g_q) (requires weaken_ok f_p f_q g_p g_q) (ensures fun _ -> True)
val subcomp (a: Type) (f_p: pre) (f_q: post a) (g_p: pre) (g_q: post a) (f: repr a f_p f_q) : Pure (repr a g_p g_q) (requires weaken_ok f_p f_q g_p g_q) (ensures fun _ -> True)
let subcomp (a:Type) (f_p:pre) (f_q:post a) (g_p:pre) (g_q:post a) (f:repr a f_p f_q) : Pure (repr a g_p g_q) (requires weaken_ok f_p f_q g_p g_q) (ensures fun _ -> True) = fun _ -> Weaken (f ())
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 26, "end_line": 168, "start_col": 0, "start_line": 161 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> f_p: HoareSTFree.pre -> f_q: HoareSTFree.post a -> g_p: HoareSTFree.pre -> g_q: HoareSTFree.post a -> f: HoareSTFree.repr a f_p f_q -> Prims.Pure (HoareSTFree.repr a g_p g_q)
Prims.Pure
[]
[]
[ "HoareSTFree.pre", "HoareSTFree.post", "HoareSTFree.repr", "Prims.unit", "HoareSTFree.Weaken", "HoareSTFree.st", "HoareSTFree.m", "HoareSTFree.weaken_ok", "Prims.l_True" ]
[]
false
false
false
false
false
let subcomp (a: Type) (f_p: pre) (f_q: post a) (g_p: pre) (g_q: post a) (f: repr a f_p f_q) : Pure (repr a g_p g_q) (requires weaken_ok f_p f_q g_p g_q) (ensures fun _ -> True) =
fun _ -> Weaken (f ())
false
HoareSTFree.fst
HoareSTFree.lift_PURE_M
val lift_PURE_M (a: Type) (wp: pure_wp a) (f: (unit -> PURE a wp)) : repr a (pure_p wp) (pure_q wp)
val lift_PURE_M (a: Type) (wp: pure_wp a) (f: (unit -> PURE a wp)) : repr a (pure_p wp) (pure_q wp)
let lift_PURE_M (a:Type) (wp:pure_wp a) (f:unit -> PURE a wp) : repr a (pure_p wp) (pure_q wp) = FStar.Monotonic.Pure.elim_pure_wp_monotonicity wp; fun _ -> let f : squash (as_requires wp) -> Dv (m st a (fun s0 -> True) (pure_q wp)) = fun _ -> let x = f () in let t : m st a (fun s0 -> s0 =...
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 12, "end_line": 200, "start_col": 0, "start_line": 187 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> wp: Prims.pure_wp a -> f: (_: Prims.unit -> Prims.PURE a) -> HoareSTFree.repr a (HoareSTFree.pure_p wp) (HoareSTFree.pure_q wp)
Prims.Tot
[ "total" ]
[]
[ "Prims.pure_wp", "Prims.unit", "HoareSTFree.Weaken", "HoareSTFree.st", "Prims.l_and", "Prims.l_True", "Prims.eq2", "Prims.l_not", "HoareSTFree.pure_p", "HoareSTFree.pure_q", "HoareSTFree.m", "HoareSTFree.Strengthen", "Prims.squash", "HoareSTFree.Ret", "Prims.pure_pre", "FStar.Monotonic...
[]
false
false
false
false
false
let lift_PURE_M (a: Type) (wp: pure_wp a) (f: (unit -> PURE a wp)) : repr a (pure_p wp) (pure_q wp) =
FStar.Monotonic.Pure.elim_pure_wp_monotonicity wp; fun _ -> let f: squash (as_requires wp) -> Dv (m st a (fun s0 -> True) (pure_q wp)) = fun _ -> let x = f () in let t:m st a (fun s0 -> s0 == s0 /\ as_ensures wp x) (pure_q wp) = Ret x in let t:m st a (fun _ -> True) (pure_q wp) = Weaken t in ...
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_precomp
val mod_precomp: len:Ghost.erased _ -> BS.bn_mod_slow_ctx_st t_limbs len
val mod_precomp: len:Ghost.erased _ -> BS.bn_mod_slow_ctx_st t_limbs len
let mod_precomp len k a res = let len1 = MA.bn_field_get_len k in BS.bn_mod_ctx len (bn_slow_precomp len1) k a res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 50, "end_line": 65, "start_col": 0, "start_line": 63 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: FStar.Ghost.erased (Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs) -> Hacl.Bignum.SafeAPI.bn_mod_slow_ctx_st Hacl.Bignum32.t_limbs (FStar.Ghost.reveal len)
Prims.Tot
[ "total" ]
[]
[ "FStar.Ghost.erased", "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.MontArithmetic.pbn_mont_ctx", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.op_Plus_Bang", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "FStar.Ghost.reveal", "Hacl.Bignum.SafeAPI.bn_mod_ctx", "Hacl.Bignum32.bn_slow...
[]
false
false
false
false
false
let mod_precomp len k a res =
let len1 = MA.bn_field_get_len k in BS.bn_mod_ctx len (bn_slow_precomp len1) k a res
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod
val mod: len:BN.meta_len t_limbs -> BS.bn_mod_slow_safe_st t_limbs len
val mod: len:BN.meta_len t_limbs -> BS.bn_mod_slow_safe_st t_limbs len
let mod len n a res = BS.mk_bn_mod_slow_safe len (BR.mk_bn_mod_slow len (kam len).AM.precomp (bn_slow_precomp len)) n a res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 103, "end_line": 46, "start_col": 0, "start_line": 45 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.SafeAPI.bn_mod_slow_safe_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.op_Plus_Bang", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Hacl.Bignum.SafeAPI.mk_bn_mod_slow_safe", "Hacl.Bignum.ModReduction.mk_bn_mod_slow", "Hacl.Bignum.AlmostMontgomery.__proj__Mkalmost_mont__item__pr...
[]
false
false
false
false
false
let mod len n a res =
BS.mk_bn_mod_slow_safe len (BR.mk_bn_mod_slow len (kam len).AM.precomp (bn_slow_precomp len)) n a res
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_inv_prime_vartime_precomp
val mod_inv_prime_vartime_precomp: len:Ghost.erased _ -> BS.bn_mod_inv_prime_ctx_st t_limbs len
val mod_inv_prime_vartime_precomp: len:Ghost.erased _ -> BS.bn_mod_inv_prime_ctx_st t_limbs len
let mod_inv_prime_vartime_precomp len k a res = let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_inv_prime_ctx len (BI.mk_bn_mod_inv_prime_precomp len1 (ke len1).BE.exp_vt_precomp) k a res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 77, "end_line": 78, "start_col": 0, "start_line": 75 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: FStar.Ghost.erased (Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs) -> Hacl.Bignum.SafeAPI.bn_mod_inv_prime_ctx_st Hacl.Bignum32.t_limbs (FStar.Ghost.reveal len)
Prims.Tot
[ "total" ]
[]
[ "FStar.Ghost.erased", "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.MontArithmetic.pbn_mont_ctx", "Hacl.Bignum.Definitions.lbignum", "FStar.Ghost.reveal", "Hacl.Bignum.SafeAPI.mk_bn_mod_inv_prime_ctx", "Hacl.Bignum.ModInv.mk_bn_mod_inv_prime_precomp", "Hacl.Bignum.Exponentiation.__pr...
[]
false
false
false
false
false
let mod_inv_prime_vartime_precomp len k a res =
let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_inv_prime_ctx len (BI.mk_bn_mod_inv_prime_precomp len1 (ke len1).BE.exp_vt_precomp) k a res
false
Vale.AES.GF128.fst
Vale.AES.GF128.lemma_shift_2_left_1
val lemma_shift_2_left_1 (lo hi:poly) : Lemma (requires degree hi < 127 /\ degree lo < 128) (ensures ( let n = monomial 128 in let a = hi *. n +. lo in let a' = shift a 1 in let (lo', hi') = quad32_shift_2_left_1 (to_quad32 lo) (to_quad32 hi) in lo' == to_quad32 (a' %. n) /\ hi' == to_quad32...
val lemma_shift_2_left_1 (lo hi:poly) : Lemma (requires degree hi < 127 /\ degree lo < 128) (ensures ( let n = monomial 128 in let a = hi *. n +. lo in let a' = shift a 1 in let (lo', hi') = quad32_shift_2_left_1 (to_quad32 lo) (to_quad32 hi) in lo' == to_quad32 (a' %. n) /\ hi' == to_quad32...
let lemma_shift_2_left_1 lo hi = let n = monomial 128 in let a = hi *. n +. lo in let a' = shift a 1 in let (qlo', qhi') = quad32_shift_2_left_1 (to_quad32 lo) (to_quad32 hi) in reveal_to_quad32 lo; reveal_to_quad32 hi; reveal_to_quad32 (a' %. n); reveal_to_quad32 (a' /. n); lemma_zero_nth 32; lemma...
{ "file_name": "vale/code/crypto/aes/Vale.AES.GF128.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 4, "end_line": 57, "start_col": 0, "start_line": 22 }
module Vale.AES.GF128 open FStar.Mul open Vale.Arch.TypesNative open Vale.Math.Poly2.Bits #reset-options "--z3rlimit 20" let lemma_shift_left_1 a = reveal_to_quad32 a; reveal_to_quad32 (shift a 1); lemma_zero_nth 32; lemma_ishl_nth_all 32; lemma_ishr_nth_all 32; lemma_ixor_nth_all 32; lemma_index_all ();...
{ "checked_file": "/", "dependencies": [ "Vale.Math.Poly2.Bits.fsti.checked", "Vale.Arch.TypesNative.fsti.checked", "Vale.Arch.Types.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": true, "s...
[ { "abbrev": false, "full_module": "Vale.Math.Poly2.Bits", "short_module": null }, { "abbrev": false, "full_module": "Vale.Arch.TypesNative", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
lo: Vale.Math.Poly2_s.poly -> hi: Vale.Math.Poly2_s.poly -> FStar.Pervasives.Lemma (requires Vale.Math.Poly2_s.degree hi < 127 /\ Vale.Math.Poly2_s.degree lo < 128) (ensures (let n = Vale.Math.Poly2_s.monomial 128 in let a = hi *. n +. lo in let a' = Vale.Math.Poly2_s.shift a 1...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Vale.Math.Poly2_s.poly", "Vale.Def.Types_s.quad32", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Vale.Math.Poly2.Bits_s.to_quad32", "Vale.Math.Poly2_s.div", "Prims.Nil", "FStar.Pervasives.pattern", "Vale.Arch.TypesNative.lemma_quad32_vec_equal", "Vale.Math.Poly2.op_Slash_Dot", ...
[]
false
false
true
false
false
let lemma_shift_2_left_1 lo hi =
let n = monomial 128 in let a = hi *. n +. lo in let a' = shift a 1 in let qlo', qhi' = quad32_shift_2_left_1 (to_quad32 lo) (to_quad32 hi) in reveal_to_quad32 lo; reveal_to_quad32 hi; reveal_to_quad32 (a' %. n); reveal_to_quad32 (a' /. n); lemma_zero_nth 32; lemma_ishl_nth_all 32; lemma_ishr_nth_all 32; lemma_ixor_nth...
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_exp_consttime
val mod_exp_consttime: len:BN.meta_len t_limbs -> BS.bn_mod_exp_safe_st t_limbs len
val mod_exp_consttime: len:BN.meta_len t_limbs -> BS.bn_mod_exp_safe_st t_limbs len
let mod_exp_consttime len n a bBits b res = BS.mk_bn_mod_exp_safe len (ke len).BE.exp_check (ke len).BE.exp_ct n a bBits b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 84, "end_line": 52, "start_col": 0, "start_line": 51 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.SafeAPI.bn_mod_exp_safe_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.size_t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Mul.op_Star", "Lib.IntTypes.bits", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Hacl.Bignum.Definitions.blocks0", "Lib.IntT...
[]
false
false
false
false
false
let mod_exp_consttime len n a bBits b res =
BS.mk_bn_mod_exp_safe len (ke len).BE.exp_check (ke len).BE.exp_ct n a bBits b res
false
HoareSTFree.fst
HoareSTFree.run
val run (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (a & st) (requires p s0) (ensures fun (x, s1) -> q s0 x s1)
val run (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (a & st) (requires p s0) (ensures fun (x, s1) -> q s0 x s1)
let rec run (#st:Type) (#a:Type) (#p:mpre st) (#q:mpost st a) (f:m st a p q) : s0:st -> Div (a & st) (requires p s0) (ensures fun (x, s1) -> q s0 x s1) = fun s0 -> match f with | Ret x -> x, s0 | _ -> let Step f, s1 = step f s0 in run f s1
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 14, "end_line": 279, "start_col": 0, "start_line": 270 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
f: HoareSTFree.m st a p q -> s0: st -> FStar.Pervasives.Div (a * st)
FStar.Pervasives.Div
[]
[]
[ "HoareSTFree.mpre", "HoareSTFree.mpost", "HoareSTFree.m", "FStar.Pervasives.Native.Mktuple2", "FStar.Pervasives.Native.tuple2", "HoareSTFree.run", "HoareSTFree.step_result", "HoareSTFree.step" ]
[ "recursion" ]
false
true
false
false
false
let rec run (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (a & st) (requires p s0) (ensures fun (x, s1) -> q s0 x s1) =
fun s0 -> match f with | Ret x -> x, s0 | _ -> let Step f, s1 = step f s0 in run f s1
false
Vale.AES.PPC64LE.GCTR.fst
Vale.AES.PPC64LE.GCTR.va_lemma_Gctr_blocks128_6way_body
val va_lemma_Gctr_blocks128_6way_body : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> old_icb:quad32 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> plain_quads:(seq quad32) -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_G...
val va_lemma_Gctr_blocks128_6way_body : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> old_icb:quad32 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> plain_quads:(seq quad32) -> Ghost (va_state & va_fuel) (requires (va_require_total va_b0 (va_code_G...
let va_lemma_Gctr_blocks128_6way_body va_b0 va_s0 alg in_b out_b old_icb key round_keys keys_b plain_quads = let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 1; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_M...
{ "file_name": "obj/Vale.AES.PPC64LE.GCTR.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 16, "end_line": 1676, "start_col": 0, "start_line": 1640 }
module Vale.AES.PPC64LE.GCTR open Vale.Def.Prop_s open Vale.Def.Opaque_s open Vale.Def.Words_s open Vale.Def.Types_s open Vale.Arch.Types open Vale.Arch.HeapImpl open FStar.Seq open Vale.AES.AES_BE_s open Vale.AES.PPC64LE.AES open Vale.AES.GCTR_BE_s open Vale.AES.GCTR_BE open Vale.AES.GCM_helpers_BE open Vale.Poly1305....
{ "checked_file": "/", "dependencies": [ "Vale.PPC64LE.State.fsti.checked", "Vale.PPC64LE.QuickCodes.fsti.checked", "Vale.PPC64LE.QuickCode.fst.checked", "Vale.PPC64LE.Memory.fsti.checked", "Vale.PPC64LE.Machine_s.fst.checked", "Vale.PPC64LE.InsVector.fsti.checked", "Vale.PPC64LE.InsStac...
[ { "abbrev": false, "full_module": "Vale.Lib.Basic", "short_module": null }, { "abbrev": false, "full_module": "Vale.AES.Types_helpers", "short_module": null }, { "abbrev": false, "full_module": "Vale.PPC64LE.QuickCodes", "short_module": null }, { "abbrev": false, ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
va_b0: Vale.PPC64LE.Decls.va_code -> va_s0: Vale.PPC64LE.Decls.va_state -> alg: Vale.AES.AES_common_s.algorithm -> in_b: Vale.PPC64LE.Memory.buffer128 -> out_b: Vale.PPC64LE.Memory.buffer128 -> old_icb: Vale.PPC64LE.Memory.quad32 -> key: FStar.Seq.Base.seq Vale.PPC64LE.Memory.nat32 -> r...
Prims.Ghost
[]
[]
[ "Vale.PPC64LE.Decls.va_code", "Vale.PPC64LE.Decls.va_state", "Vale.AES.AES_common_s.algorithm", "Vale.PPC64LE.Memory.buffer128", "Vale.PPC64LE.Memory.quad32", "FStar.Seq.Base.seq", "Vale.PPC64LE.Memory.nat32", "Vale.PPC64LE.QuickCodes.fuel", "Prims.unit", "FStar.Pervasives.Native.Mktuple2", "Val...
[]
false
false
false
false
false
let va_lemma_Gctr_blocks128_6way_body va_b0 va_s0 alg in_b out_b old_icb key round_keys keys_b plain_quads =
let va_mods:va_mods_t = [ va_Mod_mem_heaplet 1; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 8; va_Mod_reg 7; va_Mod_re...
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_exp_vartime
val mod_exp_vartime: len:BN.meta_len t_limbs -> BS.bn_mod_exp_safe_st t_limbs len
val mod_exp_vartime: len:BN.meta_len t_limbs -> BS.bn_mod_exp_safe_st t_limbs len
let mod_exp_vartime len n a bBits b res = BS.mk_bn_mod_exp_safe len (ke len).BE.exp_check (ke len).BE.exp_vt n a bBits b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 84, "end_line": 49, "start_col": 0, "start_line": 48 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> Hacl.Bignum.SafeAPI.bn_mod_exp_safe_st Hacl.Bignum32.t_limbs len
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.size_t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Mul.op_Star", "Lib.IntTypes.bits", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Hacl.Bignum.Definitions.blocks0", "Lib.IntT...
[]
false
false
false
false
false
let mod_exp_vartime len n a bBits b res =
BS.mk_bn_mod_exp_safe len (ke len).BE.exp_check (ke len).BE.exp_vt n a bBits b res
false
HoareSTFree.fst
HoareSTFree.step
val step (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (step_result st a & st) (requires p s0) (ensures fun (r, s1) -> let Step #_ #_ #p_next #q_next g = r in weaker_p p p_next s0 s1 /\ stronger_q q q_next s0 s1)
val step (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (step_result st a & st) (requires p s0) (ensures fun (r, s1) -> let Step #_ #_ #p_next #q_next g = r in weaker_p p p_next s0 s1 /\ stronger_q q q_next s0 s1)
let step (#st:Type) (#a:Type) (#p:mpre st) (#q:mpost st a) (f:m st a p q) : s0:st -> Div (step_result st a & st) (requires p s0) (ensures fun (r, s1) -> let Step #_ #_ #p_next #q_next g = r in weaker_p p p_next s0 s1 /\ stronger_q q q_next s0 s1) ...
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 37, "end_line": 265, "start_col": 0, "start_line": 250 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
f: HoareSTFree.m st a p q -> s0: st -> FStar.Pervasives.Div (HoareSTFree.step_result st a * st)
FStar.Pervasives.Div
[]
[]
[ "HoareSTFree.mpre", "HoareSTFree.mpost", "HoareSTFree.m", "FStar.Pervasives.Native.Mktuple2", "HoareSTFree.step_result", "HoareSTFree.Step", "FStar.Pervasives.Native.tuple2", "Prims.squash", "HoareSTFree.weaken_ok", "Prims.pure_pre", "Prims.l_and", "HoareSTFree.weaker_p", "HoareSTFree.strong...
[]
false
true
false
false
false
let step (#st #a: Type) (#p: mpre st) (#q: mpost st a) (f: m st a p q) (s0: st) : Div (step_result st a & st) (requires p s0) (ensures fun (r, s1) -> let Step #_ #_ #p_next #q_next g = r in weaker_p p p_next s0 s1 /\ stronger_q q q_next s0 s1) = ...
fun s0 -> match f with | Ret _ -> Step f, s0 | Act act k -> let x, s1 = act s0 in Step (k x), s1 | Weaken f -> Step f, s0 | Strengthen f -> Step (f ()), s0
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_exp_consttime_precomp
val mod_exp_consttime_precomp: len:Ghost.erased _ -> BS.bn_mod_exp_ctx_st t_limbs len
val mod_exp_consttime_precomp: len:Ghost.erased _ -> BS.bn_mod_exp_ctx_st t_limbs len
let mod_exp_consttime_precomp len k a bBits b res = let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_exp_ctx len (ke len1).BE.exp_ct_precomp k a bBits b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 70, "end_line": 73, "start_col": 0, "start_line": 71 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: FStar.Ghost.erased (Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs) -> Hacl.Bignum.SafeAPI.bn_mod_exp_ctx_st Hacl.Bignum32.t_limbs (FStar.Ghost.reveal len)
Prims.Tot
[ "total" ]
[]
[ "FStar.Ghost.erased", "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.MontArithmetic.pbn_mont_ctx", "Hacl.Bignum.Definitions.lbignum", "FStar.Ghost.reveal", "Lib.IntTypes.size_t", "Hacl.Bignum.Definitions.blocks0", "Lib.IntTypes.size", "Lib.IntTypes.bits", "Hacl.Bignum.SafeAPI.mk_b...
[]
false
false
false
false
false
let mod_exp_consttime_precomp len k a bBits b res =
let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_exp_ctx len (ke len1).BE.exp_ct_precomp k a bBits b res
false
Hacl.Bignum32.fst
Hacl.Bignum32.bn_to_bytes_le
val bn_to_bytes_le: len:_ -> Hacl.Bignum.Convert.bn_to_bytes_le_st t_limbs len
val bn_to_bytes_le: len:_ -> Hacl.Bignum.Convert.bn_to_bytes_le_st t_limbs len
let bn_to_bytes_le len b res = Hacl.Bignum.Convert.mk_bn_to_bytes_le false len b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 55, "end_line": 90, "start_col": 0, "start_line": 89 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Lib.IntTypes.size_t { 0 < Lib.IntTypes.v len /\ Lib.IntTypes.numbytes Hacl.Bignum32.t_limbs * Lib.IntTypes.v (Hacl.Bignum.Definitions.blocks len (Lib.IntTypes.size (Lib.IntTypes.numbytes Hacl.Bignum32.t_limbs))) <= Lib.IntTypes.max_size_t } -> Hacl...
Prims.Tot
[ "total" ]
[]
[ "Lib.IntTypes.size_t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Prims.op_LessThanOrEqual", "FStar.Mul.op_Star", "Lib.IntTypes.numbytes", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.blocks", "Lib.IntTypes.size", "Lib.I...
[]
false
false
false
false
false
let bn_to_bytes_le len b res =
Hacl.Bignum.Convert.mk_bn_to_bytes_le false len b res
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_mod_mul_distr
val lemma_mod_mul_distr (a b:int) (n:pos) : Lemma (a * b % n = (a % n) * (b % n) % n)
val lemma_mod_mul_distr (a b:int) (n:pos) : Lemma (a * b % n = (a % n) * (b % n) % n)
let lemma_mod_mul_distr a b n = Math.Lemmas.lemma_mod_mul_distr_l a b n; Math.Lemmas.lemma_mod_mul_distr_r (a % n) b n
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 47, "end_line": 23, "start_col": 0, "start_line": 21 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> n: Prims.pos -> FStar.Pervasives.Lemma (ensures a * b % n = (a % n) * (b % n) % n)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.pos", "FStar.Math.Lemmas.lemma_mod_mul_distr_r", "Prims.op_Modulus", "Prims.unit", "FStar.Math.Lemmas.lemma_mod_mul_distr_l" ]
[]
true
false
true
false
false
let lemma_mod_mul_distr a b n =
Math.Lemmas.lemma_mod_mul_distr_l a b n; Math.Lemmas.lemma_mod_mul_distr_r (a % n) b n
false
HoareSTFree.fst
HoareSTFree.test
val test: Prims.unit -> M unit (fun _ -> True) (fun _ _ s1 -> st_q s1)
val test: Prims.unit -> M unit (fun _ -> True) (fun _ _ s1 -> st_q s1)
let test () : M unit (fun _ -> True) (fun _ _ s1 -> st_q s1) = g (); f (); h ()
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 6, "end_line": 222, "start_col": 0, "start_line": 219 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
_: Prims.unit -> HoareSTFree.M Prims.unit
HoareSTFree.M
[]
[]
[ "Prims.unit", "HoareSTFree.h", "HoareSTFree.f", "HoareSTFree.g", "HoareSTFree.st", "Prims.l_True", "HoareSTFree.st_q" ]
[]
false
true
false
false
false
let test () : M unit (fun _ -> True) (fun _ _ s1 -> st_q s1) =
g (); f (); h ()
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_ab_le_cd
val lemma_ab_le_cd (a b c d:nat) : Lemma (requires a <= c /\ b <= d) (ensures a * b <= c * d)
val lemma_ab_le_cd (a b c d:nat) : Lemma (requires a <= c /\ b <= d) (ensures a * b <= c * d)
let lemma_ab_le_cd a b c d = Math.Lemmas.lemma_mult_le_left a b d; Math.Lemmas.lemma_mult_le_right d a c
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 39, "end_line": 37, "start_col": 0, "start_line": 35 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.nat -> b: Prims.nat -> c: Prims.nat -> d: Prims.nat -> FStar.Pervasives.Lemma (requires a <= c /\ b <= d) (ensures a * b <= c * d)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Math.Lemmas.lemma_mult_le_right", "Prims.unit", "FStar.Math.Lemmas.lemma_mult_le_left" ]
[]
true
false
true
false
false
let lemma_ab_le_cd a b c d =
Math.Lemmas.lemma_mult_le_left a b d; Math.Lemmas.lemma_mult_le_right d a c
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_swap_mul3
val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b)
val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b)
let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c } a * (c * b); (==) { Math.Lemmas.paren_mul_right a c b } a * c * b; }
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 17, "start_col": 0, "start_line": 8 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0"
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> c: Prims.int -> FStar.Pervasives.Lemma (ensures (a * b) * c == (a * c) * b)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "FStar.Calc.calc_finish", "Prims.eq2", "FStar.Mul.op_Star", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "FStar.Math.Lemmas.paren_mul_right", "Prims.squash", "FStar.Math.Lemmas.swap_...
[]
false
false
true
false
false
let lemma_swap_mul3 a b c =
calc ( == ) { (a * b) * c; ( == ) { Math.Lemmas.paren_mul_right a b c } a * (b * c); ( == ) { Math.Lemmas.swap_mul b c } a * (c * b); ( == ) { Math.Lemmas.paren_mul_right a c b } (a * c) * b; }
false
Apply.fst
Apply.lem1
val lem1 : Prims.unit
let lem1 = assert (x == x) by tau ()
{ "file_name": "examples/native_tactics/Apply.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 36, "end_line": 30, "start_col": 0, "start_line": 30 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Tactics.V2.fst.checked", "FStar.Tactics.Effect.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked" ], "interface_file": false, "source_file": "Apply.fst" }
[ { "abbrev": false, "full_module": "FStar.Tactics.V2", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Prims.unit
Prims.Tot
[ "total" ]
[]
[ "FStar.Tactics.Effect.assert_by_tactic", "Prims.eq2", "Prims.int", "Apply.x", "Prims.unit", "Apply.tau" ]
[]
false
false
false
true
false
let lem1 =
FStar.Tactics.Effect.assert_by_tactic (x == x) (fun _ -> (); tau ())
false
Apply.fst
Apply.tau
val tau: Prims.unit -> Tac unit
val tau: Prims.unit -> Tac unit
let tau () : Tac unit = apply_lemma (`refl)
{ "file_name": "examples/native_tactics/Apply.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 23, "end_line": 28, "start_col": 0, "start_line": 27 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Tactics.V2.fst.checked", "FStar.Tactics.Effect.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked" ], "interface_file": false, "source_file": "Apply.fst" }
[ { "abbrev": false, "full_module": "FStar.Tactics.V2", "short_module": null }, { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
_: Prims.unit -> FStar.Tactics.Effect.Tac Prims.unit
FStar.Tactics.Effect.Tac
[]
[]
[ "Prims.unit", "FStar.Tactics.V2.Derived.apply_lemma" ]
[]
false
true
false
false
false
let tau () : Tac unit =
apply_lemma (`refl)
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_mod_sub_distr
val lemma_mod_sub_distr (a b:int) (n:pos) : Lemma ((a - b) % n = (a % n - b % n) % n)
val lemma_mod_sub_distr (a b:int) (n:pos) : Lemma ((a - b) % n = (a % n - b % n) % n)
let lemma_mod_sub_distr a b n = Math.Lemmas.lemma_mod_plus_distr_l a (- b) n; Math.Lemmas.lemma_mod_sub_distr (a % n) b n
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 45, "end_line": 29, "start_col": 0, "start_line": 27 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> n: Prims.pos -> FStar.Pervasives.Lemma (ensures (a - b) % n = (a % n - b % n) % n)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.pos", "FStar.Math.Lemmas.lemma_mod_sub_distr", "Prims.op_Modulus", "Prims.unit", "FStar.Math.Lemmas.lemma_mod_plus_distr_l", "Prims.op_Minus" ]
[]
true
false
true
false
false
let lemma_mod_sub_distr a b n =
Math.Lemmas.lemma_mod_plus_distr_l a (- b) n; Math.Lemmas.lemma_mod_sub_distr (a % n) b n
false
HoareSTFree.fst
HoareSTFree.bind
val bind (a b: Type) (f_p: pre) (f_q: post a) (g_p: (a -> pre)) (g_q: (a -> post b)) (f: repr a f_p f_q) (g: (x: a -> repr b (g_p x) (g_q x))) : repr b (act_p f_p f_q g_p) (act_q f_q g_q)
val bind (a b: Type) (f_p: pre) (f_q: post a) (g_p: (a -> pre)) (g_q: (a -> post b)) (f: repr a f_p f_q) (g: (x: a -> repr b (g_p x) (g_q x))) : repr b (act_p f_p f_q g_p) (act_q f_q g_q)
let rec bind (a b:Type) (f_p:pre) (f_q:post a) (g_p:a -> pre) (g_q:a -> post b) (f:repr a f_p f_q) (g:(x:a -> repr b (g_p x) (g_q x))) : repr b (act_p f_p f_q g_p) (act_q f_q g_q) = fun _ -> let f = f () in match f with | Ret x -> Weaken (g x ()) | Act #_ #c #a_p #a_q act #_ #_ #_ k -> l...
{ "file_name": "examples/layeredeffects/HoareSTFree.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 14, "end_line": 157, "start_col": 0, "start_line": 139 }
(* Copyright 2008-2022 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Monotonic.Pure.fst.checked" ], "interface_file": false, "source_file": "HoareSTFree.fst" }
[ { "abbrev": false, "full_module": "FStar.Monotonic.Pure", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> b: Type -> f_p: HoareSTFree.pre -> f_q: HoareSTFree.post a -> g_p: (_: a -> HoareSTFree.pre) -> g_q: (_: a -> HoareSTFree.post b) -> f: HoareSTFree.repr a f_p f_q -> g: (x: a -> HoareSTFree.repr b (g_p x) (g_q x)) -> HoareSTFree.repr b (HoareSTFree.act_p f_p f_q g_p) (Hoare...
Prims.Tot
[ "total" ]
[]
[ "HoareSTFree.pre", "HoareSTFree.post", "HoareSTFree.repr", "Prims.unit", "HoareSTFree.mpost", "HoareSTFree.st", "HoareSTFree.Weaken", "HoareSTFree.act_p", "HoareSTFree.act_q", "HoareSTFree.m", "HoareSTFree.mpre", "FStar.Pervasives.Native.tuple2", "Prims.l_and", "Prims.l_Forall", "Prims.l...
[ "recursion" ]
false
false
false
false
false
let rec bind (a b: Type) (f_p: pre) (f_q: post a) (g_p: (a -> pre)) (g_q: (a -> post b)) (f: repr a f_p f_q) (g: (x: a -> repr b (g_p x) (g_q x))) : repr b (act_p f_p f_q g_p) (act_q f_q g_q) =
fun _ -> let f = f () in match f with | Ret x -> Weaken (g x ()) | Act #_ #c #a_p #a_q act #_ #_ #_ k -> let k' = fun (x: c) -> (bind _ _ _ _ _ _ (fun _ -> k x) g) () in Weaken (Act #_ #c #a_p #a_q act #b #_ #_ k') | Weaken f -> Weaken ((bind _ _ _ _ _ _ (fun _ -> f) g) ()) | Strengthen #_ #_ #phi #...
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_ab_lt_cd
val lemma_ab_lt_cd (a b c d:pos) : Lemma (requires a < c /\ b < d) (ensures a * b < c * d)
val lemma_ab_lt_cd (a b c d:pos) : Lemma (requires a < c /\ b < d) (ensures a * b < c * d)
let lemma_ab_lt_cd a b c d = Math.Lemmas.lemma_mult_lt_left a b d; Math.Lemmas.lemma_mult_lt_right d a c
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 39, "end_line": 45, "start_col": 0, "start_line": 43 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.pos -> b: Prims.pos -> c: Prims.pos -> d: Prims.pos -> FStar.Pervasives.Lemma (requires a < c /\ b < d) (ensures a * b < c * d)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.Math.Lemmas.lemma_mult_lt_right", "Prims.unit", "FStar.Math.Lemmas.lemma_mult_lt_left" ]
[]
true
false
true
false
false
let lemma_ab_lt_cd a b c d =
Math.Lemmas.lemma_mult_lt_left a b d; Math.Lemmas.lemma_mult_lt_right d a c
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr_pow
val lemma_distr_pow (a b:int) (c d:nat) : Lemma ((a + b * pow2 c) * pow2 d = a * pow2 d + b * pow2 (c + d))
val lemma_distr_pow (a b:int) (c d:nat) : Lemma ((a + b * pow2 c) * pow2 d = a * pow2 d + b * pow2 (c + d))
let lemma_distr_pow a b c d = calc (==) { (a + b * pow2 c) * pow2 d; (==) { Math.Lemmas.distributivity_add_left a (b * pow2 c) (pow2 d) } a * pow2 d + b * pow2 c * pow2 d; (==) { Math.Lemmas.paren_mul_right b (pow2 c) (pow2 d); Math.Lemmas.pow2_plus c d } a * pow2 d + b * pow2 (c + d); }
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 77, "start_col": 0, "start_line": 70 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> c: Prims.nat -> d: Prims.nat -> FStar.Pervasives.Lemma (ensures (a + b * Prims.pow2 c) * Prims.pow2 d = a * Prims.pow2 d + b * Prims.pow2 (c + d))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.nat", "FStar.Calc.calc_finish", "Prims.eq2", "FStar.Mul.op_Star", "Prims.op_Addition", "Prims.pow2", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "FStar.Math.Lemmas.distribu...
[]
false
false
true
false
false
let lemma_distr_pow a b c d =
calc ( == ) { (a + b * pow2 c) * pow2 d; ( == ) { Math.Lemmas.distributivity_add_left a (b * pow2 c) (pow2 d) } a * pow2 d + (b * pow2 c) * pow2 d; ( == ) { (Math.Lemmas.paren_mul_right b (pow2 c) (pow2 d); Math.Lemmas.pow2_plus c d) } a * pow2 d + b * pow2 (c + d); }
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr_pow_pow
val lemma_distr_pow_pow (a:int) (b:nat) (c:int) (d e:nat) : Lemma ((a * pow2 b + c * pow2 d) * pow2 e = a * pow2 (b + e) + c * pow2 (d + e))
val lemma_distr_pow_pow (a:int) (b:nat) (c:int) (d e:nat) : Lemma ((a * pow2 b + c * pow2 d) * pow2 e = a * pow2 (b + e) + c * pow2 (d + e))
let lemma_distr_pow_pow a b c d e = calc (==) { (a * pow2 b + c * pow2 d) * pow2 e; (==) { lemma_distr_pow (a * pow2 b) c d e } a * pow2 b * pow2 e + c * pow2 (d + e); (==) { Math.Lemmas.paren_mul_right a (pow2 b) (pow2 e); Math.Lemmas.pow2_plus b e } a * pow2 (b + e) + c * pow2 (d + e); }
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 89, "start_col": 0, "start_line": 82 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.nat -> c: Prims.int -> d: Prims.nat -> e: Prims.nat -> FStar.Pervasives.Lemma (ensures (a * Prims.pow2 b + c * Prims.pow2 d) * Prims.pow2 e = a * Prims.pow2 (b + e) + c * Prims.pow2 (d + e))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.nat", "FStar.Calc.calc_finish", "Prims.eq2", "FStar.Mul.op_Star", "Prims.op_Addition", "Prims.pow2", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "Hacl.Spec.K256.MathLemmas....
[]
false
false
true
false
false
let lemma_distr_pow_pow a b c d e =
calc ( == ) { (a * pow2 b + c * pow2 d) * pow2 e; ( == ) { lemma_distr_pow (a * pow2 b) c d e } (a * pow2 b) * pow2 e + c * pow2 (d + e); ( == ) { (Math.Lemmas.paren_mul_right a (pow2 b) (pow2 e); Math.Lemmas.pow2_plus b e) } a * pow2 (b + e) + c * pow2 (d + e); }
false
Steel.Closure.fst
Steel.Closure.new_counter
val new_counter (u:unit) : SteelT ctr_t emp (fun r -> dfst r 0)
val new_counter (u:unit) : SteelT ctr_t emp (fun r -> dfst r 0)
let new_counter = new_counter'
{ "file_name": "lib/steel/Steel.Closure.fst", "git_rev": "f984200f79bdc452374ae994a5ca837496476c41", "git_url": "https://github.com/FStarLang/steel.git", "project_name": "steel" }
{ "end_col": 30, "end_line": 47, "start_col": 0, "start_line": 47 }
(* Copyright 2020 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "checked_file": "/", "dependencies": [ "Steel.Reference.fsti.checked", "Steel.Memory.fsti.checked", "Steel.FractionalPermission.fst.checked", "Steel.Effect.Atomic.fsti.checked", "Steel.Effect.fsti.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": t...
[ { "abbrev": false, "full_module": "Steel.FractionalPermission", "short_module": null }, { "abbrev": false, "full_module": "Steel.Reference", "short_module": null }, { "abbrev": false, "full_module": "Steel.Effect", "short_module": null }, { "abbrev": false, "f...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
u16: Prims.unit -> Steel.Effect.SteelT Steel.Closure.ctr_t
Steel.Effect.SteelT
[]
[]
[ "Steel.Closure.new_counter'" ]
[]
false
true
false
false
false
let new_counter =
new_counter'
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr_eucl
val lemma_distr_eucl (a b:int) : Lemma ((a / pow2 52 + b) * pow2 52 + a % pow2 52 = a + b * pow2 52)
val lemma_distr_eucl (a b:int) : Lemma ((a / pow2 52 + b) * pow2 52 + a % pow2 52 = a + b * pow2 52)
let lemma_distr_eucl a b = lemma_distr_eucl_mul_add 1 a b (pow2 52)
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 67, "end_line": 123, "start_col": 0, "start_line": 123 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> FStar.Pervasives.Lemma (ensures (a / Prims.pow2 52 + b) * Prims.pow2 52 + a % Prims.pow2 52 = a + b * Prims.pow2 52)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Hacl.Spec.K256.MathLemmas.lemma_distr_eucl_mul_add", "Prims.pow2", "Prims.unit" ]
[]
true
false
true
false
false
let lemma_distr_eucl a b =
lemma_distr_eucl_mul_add 1 a b (pow2 52)
false
Hacl.Bignum32.fst
Hacl.Bignum32.mul
val mul: len:BN.meta_len t_limbs -> a:lbignum t_limbs len -> BN.bn_karatsuba_mul_st t_limbs len a
val mul: len:BN.meta_len t_limbs -> a:lbignum t_limbs len -> BN.bn_karatsuba_mul_st t_limbs len a
let mul len a b res = (ke len).BE.bn.BN.mul a b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 31, "end_line": 36, "start_col": 0, "start_line": 35 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> a: Hacl.Bignum32.lbignum Hacl.Bignum32.t_limbs len -> Hacl.Bignum.bn_karatsuba_mul_st Hacl.Bignum32.t_limbs len a
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum32.lbignum", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.op_Plus_Bang", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Hacl.Bignum.__proj__Mkbn__item__mul", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Prim...
[]
false
false
false
false
false
let mul len a b res =
(ke len).BE.bn.BN.mul a b res
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_bound_mul64_wide
val lemma_bound_mul64_wide (ma mb:nat) (mma mmb:nat) (a b:nat) : Lemma (requires a <= ma * mma /\ b <= mb * mmb) (ensures a * b <= ma * mb * (mma * mmb))
val lemma_bound_mul64_wide (ma mb:nat) (mma mmb:nat) (a b:nat) : Lemma (requires a <= ma * mma /\ b <= mb * mmb) (ensures a * b <= ma * mb * (mma * mmb))
let lemma_bound_mul64_wide ma mb mma mmb a b = calc (<=) { a * b; (<=) { lemma_ab_le_cd a b (ma * mma) (mb * mmb) } (ma * mma) * (mb * mmb); (==) { Math.Lemmas.paren_mul_right ma mma (mb * mmb) } ma * (mma * (mb * mmb)); (==) { Math.Lemmas.paren_mul_right mma mb mmb; Math.Lemmas.sw...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 66, "start_col": 0, "start_line": 52 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
ma: Prims.nat -> mb: Prims.nat -> mma: Prims.nat -> mmb: Prims.nat -> a: Prims.nat -> b: Prims.nat -> FStar.Pervasives.Lemma (requires a <= ma * mma /\ b <= mb * mmb) (ensures a * b <= (ma * mb) * (mma * mmb))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Calc.calc_finish", "Prims.int", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Mul.op_Star", "Prims.Cons", "FStar.Preorder.relation", "Prims.eq2", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "Hacl.Spec.K256.MathL...
[]
false
false
true
false
false
let lemma_bound_mul64_wide ma mb mma mmb a b =
calc ( <= ) { a * b; ( <= ) { lemma_ab_le_cd a b (ma * mma) (mb * mmb) } (ma * mma) * (mb * mmb); ( == ) { Math.Lemmas.paren_mul_right ma mma (mb * mmb) } ma * (mma * (mb * mmb)); ( == ) { (Math.Lemmas.paren_mul_right mma mb mmb; Math.Lemmas.swap_mul mma mb; Math.Lemmas.paren_mul_right mb mma mmb) }...
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_a_plus_b_pow2_mod2
val lemma_a_plus_b_pow2_mod2 (a b:int) (c:pos) : Lemma ((a + b * pow2 c) % 2 = a % 2)
val lemma_a_plus_b_pow2_mod2 (a b:int) (c:pos) : Lemma ((a + b * pow2 c) % 2 = a % 2)
let lemma_a_plus_b_pow2_mod2 a b c = assert_norm (pow2 1 = 2); Math.Lemmas.lemma_mod_plus_distr_r a (b * pow2 c) 2; Math.Lemmas.pow2_multiplication_modulo_lemma_1 b 1 c
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 54, "end_line": 130, "start_col": 0, "start_line": 127 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.int -> b: Prims.int -> c: Prims.pos -> FStar.Pervasives.Lemma (ensures (a + b * Prims.pow2 c) % 2 = a % 2)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.pos", "FStar.Math.Lemmas.pow2_multiplication_modulo_lemma_1", "Prims.unit", "FStar.Math.Lemmas.lemma_mod_plus_distr_r", "FStar.Mul.op_Star", "Prims.pow2", "FStar.Pervasives.assert_norm", "Prims.b2t", "Prims.op_Equality" ]
[]
true
false
true
false
false
let lemma_a_plus_b_pow2_mod2 a b c =
assert_norm (pow2 1 = 2); Math.Lemmas.lemma_mod_plus_distr_r a (b * pow2 c) 2; Math.Lemmas.pow2_multiplication_modulo_lemma_1 b 1 c
false
Hacl.Bignum32.fst
Hacl.Bignum32.mod_exp_vartime_precomp
val mod_exp_vartime_precomp: len:Ghost.erased _ -> BS.bn_mod_exp_ctx_st t_limbs len
val mod_exp_vartime_precomp: len:Ghost.erased _ -> BS.bn_mod_exp_ctx_st t_limbs len
let mod_exp_vartime_precomp len k a bBits b res = let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_exp_ctx len (ke len1).BE.exp_vt_precomp k a bBits b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 70, "end_line": 69, "start_col": 0, "start_line": 67 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: FStar.Ghost.erased (Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs) -> Hacl.Bignum.SafeAPI.bn_mod_exp_ctx_st Hacl.Bignum32.t_limbs (FStar.Ghost.reveal len)
Prims.Tot
[ "total" ]
[]
[ "FStar.Ghost.erased", "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.MontArithmetic.pbn_mont_ctx", "Hacl.Bignum.Definitions.lbignum", "FStar.Ghost.reveal", "Lib.IntTypes.size_t", "Hacl.Bignum.Definitions.blocks0", "Lib.IntTypes.size", "Lib.IntTypes.bits", "Hacl.Bignum.SafeAPI.mk_b...
[]
false
false
false
false
false
let mod_exp_vartime_precomp len k a bBits b res =
let len1 = MA.bn_field_get_len k in BS.mk_bn_mod_exp_ctx len (ke len1).BE.exp_vt_precomp k a bBits b res
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr_eucl_mul
val lemma_distr_eucl_mul (r a:int) (b:pos) : Lemma (r * (a % b) + r * (a / b) * b = r * a)
val lemma_distr_eucl_mul (r a:int) (b:pos) : Lemma (r * (a % b) + r * (a / b) * b = r * a)
let lemma_distr_eucl_mul r a b = calc (==) { r * (a % b) + r * (a / b) * b; (==) { Math.Lemmas.paren_mul_right r (a / b) b } r * (a % b) + r * ((a / b) * b); (==) { Math.Lemmas.distributivity_add_right r (a % b) (a / b * b) } r * (a % b + a / b * b); (==) { Math.Lemmas.euclidean_division_defin...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 102, "start_col": 0, "start_line": 93 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
r: Prims.int -> a: Prims.int -> b: Prims.pos -> FStar.Pervasives.Lemma (ensures r * (a % b) + (r * (a / b)) * b = r * a)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.pos", "FStar.Calc.calc_finish", "Prims.eq2", "Prims.op_Addition", "FStar.Mul.op_Star", "Prims.op_Modulus", "Prims.op_Division", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", ...
[]
false
false
true
false
false
let lemma_distr_eucl_mul r a b =
calc ( == ) { r * (a % b) + (r * (a / b)) * b; ( == ) { Math.Lemmas.paren_mul_right r (a / b) b } r * (a % b) + r * ((a / b) * b); ( == ) { Math.Lemmas.distributivity_add_right r (a % b) ((a / b) * b) } r * (a % b + (a / b) * b); ( == ) { Math.Lemmas.euclidean_division_definition a b } r * a; }
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_a_div_b_plus_c_mod_d_mul_e
val lemma_a_div_b_plus_c_mod_d_mul_e (a b c d e:nat) : Lemma (requires a / pow2 b < pow2 e) (ensures a / pow2 b + c % pow2 d * pow2 e < pow2 (d + e))
val lemma_a_div_b_plus_c_mod_d_mul_e (a b c d e:nat) : Lemma (requires a / pow2 b < pow2 e) (ensures a / pow2 b + c % pow2 d * pow2 e < pow2 (d + e))
let lemma_a_div_b_plus_c_mod_d_mul_e a b c d e = let t_r = c % pow2 d * pow2 e in Math.Lemmas.lemma_mult_le_right (pow2 e) (c % pow2 d) (pow2 d - 1); assert (t_r <= (pow2 d - 1) * pow2 e); assert (t_r <= pow2 d * pow2 e - pow2 e); Math.Lemmas.pow2_plus d e; assert (t_r <= pow2 (d + e) - pow2 e); assert (a...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 58, "end_line": 265, "start_col": 0, "start_line": 258 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.nat -> b: Prims.nat -> c: Prims.nat -> d: Prims.nat -> e: Prims.nat -> FStar.Pervasives.Lemma (requires a / Prims.pow2 b < Prims.pow2 e) (ensures a / Prims.pow2 b + (c % Prims.pow2 d) * Prims.pow2 e < Prims.pow2 (d + e))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "Prims._assert", "Prims.b2t", "Prims.op_LessThan", "Prims.op_Addition", "Prims.op_Division", "Prims.pow2", "FStar.Mul.op_Star", "Prims.op_Modulus", "Prims.unit", "Prims.op_LessThanOrEqual", "Prims.op_Subtraction", "FStar.Math.Lemmas.pow2_plus", "FStar.Math.Lemmas.lemma_mult_le...
[]
true
false
true
false
false
let lemma_a_div_b_plus_c_mod_d_mul_e a b c d e =
let t_r = (c % pow2 d) * pow2 e in Math.Lemmas.lemma_mult_le_right (pow2 e) (c % pow2 d) (pow2 d - 1); assert (t_r <= (pow2 d - 1) * pow2 e); assert (t_r <= pow2 d * pow2 e - pow2 e); Math.Lemmas.pow2_plus d e; assert (t_r <= pow2 (d + e) - pow2 e); assert (a / pow2 b + (c % pow2 d) * pow2 e < pow2 (d + e))
false
Hacl.Bignum32.fst
Hacl.Bignum32.sqr
val sqr: len:BN.meta_len t_limbs -> a:lbignum t_limbs len -> BN.bn_karatsuba_sqr_st t_limbs len a
val sqr: len:BN.meta_len t_limbs -> a:lbignum t_limbs len -> BN.bn_karatsuba_sqr_st t_limbs len a
let sqr len a res = (ke len).BE.bn.BN.sqr a res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 29, "end_line": 39, "start_col": 0, "start_line": 38 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Hacl.Bignum.meta_len Hacl.Bignum32.t_limbs -> a: Hacl.Bignum32.lbignum Hacl.Bignum32.t_limbs len -> Hacl.Bignum.bn_karatsuba_sqr_st Hacl.Bignum32.t_limbs len a
Prims.Tot
[ "total" ]
[]
[ "Hacl.Bignum.meta_len", "Hacl.Bignum32.t_limbs", "Hacl.Bignum32.lbignum", "Hacl.Bignum.Definitions.lbignum", "Lib.IntTypes.op_Plus_Bang", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Hacl.Bignum.__proj__Mkbn__item__sqr", "Hacl.Bignum.Exponentiation.__proj__Mkexp__item__bn", "Hacl.Bignum32.ke", "Prim...
[]
false
false
false
false
false
let sqr len a res =
(ke len).BE.bn.BN.sqr a res
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr5
val lemma_distr5 (a0 a1 a2 a3 a4 b:int) : Lemma ((a0 + a1 + a2 + a3 + a4) * b = a0 * b + a1 * b + a2 * b + a3 * b + a4 * b)
val lemma_distr5 (a0 a1 a2 a3 a4 b:int) : Lemma ((a0 + a1 + a2 + a3 + a4) * b = a0 * b + a1 * b + a2 * b + a3 * b + a4 * b)
let lemma_distr5 a0 a1 a2 a3 a4 b = calc (==) { (a0 + a1 + a2 + a3 + a4) * b; (==) { Math.Lemmas.distributivity_add_left a0 (a1 + a2 + a3 + a4) b } a0 * b + (a1 + a2 + a3 + a4) * b; (==) { Math.Lemmas.distributivity_add_left a1 (a2 + a3 + a4) b } a0 * b + a1 * b + (a2 + a3 + a4) * b; (==) { Ma...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 183, "start_col": 0, "start_line": 172 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a0: Prims.int -> a1: Prims.int -> a2: Prims.int -> a3: Prims.int -> a4: Prims.int -> b: Prims.int -> FStar.Pervasives.Lemma (ensures (a0 + a1 + a2 + a3 + a4) * b = a0 * b + a1 * b + a2 * b + a3 * b + a4 * b)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "FStar.Calc.calc_finish", "Prims.eq2", "FStar.Mul.op_Star", "Prims.op_Addition", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "FStar.Math.Lemmas.distributivity_add_left", "Prims.squa...
[]
false
false
true
false
false
let lemma_distr5 a0 a1 a2 a3 a4 b =
calc ( == ) { (a0 + a1 + a2 + a3 + a4) * b; ( == ) { Math.Lemmas.distributivity_add_left a0 (a1 + a2 + a3 + a4) b } a0 * b + (a1 + a2 + a3 + a4) * b; ( == ) { Math.Lemmas.distributivity_add_left a1 (a2 + a3 + a4) b } a0 * b + a1 * b + (a2 + a3 + a4) * b; ( == ) { Math.Lemmas.distributivity_add_left a2 (a3 +...
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_a_mod_b_mul_c_mod_d
val lemma_a_mod_b_mul_c_mod_d (a b c d:nat) : Lemma (requires c <= d /\ b <= d - c) (ensures (a % pow2 b) * pow2 c % pow2 d = (a % pow2 b) * pow2 c)
val lemma_a_mod_b_mul_c_mod_d (a b c d:nat) : Lemma (requires c <= d /\ b <= d - c) (ensures (a % pow2 b) * pow2 c % pow2 d = (a % pow2 b) * pow2 c)
let lemma_a_mod_b_mul_c_mod_d a b c d = Math.Lemmas.pow2_multiplication_modulo_lemma_2 (a % pow2 b) d c; Math.Lemmas.pow2_modulo_modulo_lemma_2 a (d - c) b
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 52, "end_line": 274, "start_col": 0, "start_line": 272 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.nat -> b: Prims.nat -> c: Prims.nat -> d: Prims.nat -> FStar.Pervasives.Lemma (requires c <= d /\ b <= d - c) (ensures (a % Prims.pow2 b) * Prims.pow2 c % Prims.pow2 d = (a % Prims.pow2 b) * Prims.pow2 c)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Math.Lemmas.pow2_modulo_modulo_lemma_2", "Prims.op_Subtraction", "Prims.unit", "FStar.Math.Lemmas.pow2_multiplication_modulo_lemma_2", "Prims.op_Modulus", "Prims.pow2" ]
[]
true
false
true
false
false
let lemma_a_mod_b_mul_c_mod_d a b c d =
Math.Lemmas.pow2_multiplication_modulo_lemma_2 (a % pow2 b) d c; Math.Lemmas.pow2_modulo_modulo_lemma_2 a (d - c) b
false
Hacl.Bignum32.fst
Hacl.Bignum32.bn_to_bytes_be
val bn_to_bytes_be: len:_ -> Hacl.Bignum.Convert.bn_to_bytes_be_st t_limbs len
val bn_to_bytes_be: len:_ -> Hacl.Bignum.Convert.bn_to_bytes_be_st t_limbs len
let bn_to_bytes_be len b res = Hacl.Bignum.Convert.mk_bn_to_bytes_be false len b res
{ "file_name": "code/bignum/Hacl.Bignum32.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 55, "end_line": 87, "start_col": 0, "start_line": 86 }
module Hacl.Bignum32 open FStar.Mul module BN = Hacl.Bignum module BE = Hacl.Bignum.Exponentiation module BR = Hacl.Bignum.ModReduction module AM = Hacl.Bignum.AlmostMontgomery module MA = Hacl.Bignum.MontArithmetic module BI = Hacl.Bignum.ModInv module BM = Hacl.Bignum.Montgomery #set-options "--z3rlimit 50 --fuel ...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Hacl.Bignum.Montgomery.fsti.checked", "Hacl.Bignum.MontArithmetic.fsti.checked", "Hacl.Bignum.ModReduction.fst.checked", "Hacl.Bignum.ModInv.fst.checked", "Hacl.Bignum.Exponentiation.fsti.checked", "Hacl.Bignum.Convert.fst.ch...
[ { "abbrev": true, "full_module": "Hacl.Bignum.Montgomery", "short_module": "BM" }, { "abbrev": true, "full_module": "Hacl.Bignum.ModInv", "short_module": "BI" }, { "abbrev": true, "full_module": "Hacl.Bignum.MontArithmetic", "short_module": "MA" }, { "abbrev": tru...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
len: Lib.IntTypes.size_t { 0 < Lib.IntTypes.v len /\ Lib.IntTypes.numbytes Hacl.Bignum32.t_limbs * Lib.IntTypes.v (Hacl.Bignum.Definitions.blocks len (Lib.IntTypes.size (Lib.IntTypes.numbytes Hacl.Bignum32.t_limbs))) <= Lib.IntTypes.max_size_t } -> Hacl...
Prims.Tot
[ "total" ]
[]
[ "Lib.IntTypes.size_t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "Prims.op_LessThanOrEqual", "FStar.Mul.op_Star", "Lib.IntTypes.numbytes", "Hacl.Bignum32.t_limbs", "Hacl.Bignum.Definitions.blocks", "Lib.IntTypes.size", "Lib.I...
[]
false
false
false
false
false
let bn_to_bytes_be len b res =
Hacl.Bignum.Convert.mk_bn_to_bytes_be false len b res
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_distr_eucl_mul_add
val lemma_distr_eucl_mul_add (r a c:int) (b:pos) : Lemma (r * (a % b) + r * (a / b + c) * b = r * a + r * c * b)
val lemma_distr_eucl_mul_add (r a c:int) (b:pos) : Lemma (r * (a % b) + r * (a / b + c) * b = r * a + r * c * b)
let lemma_distr_eucl_mul_add r a c b = calc (==) { r * (a % b) + r * (a / b + c) * b; (==) { Math.Lemmas.paren_mul_right r (a / b + c) b } r * (a % b) + r * ((a / b + c) * b); (==) { Math.Lemmas.distributivity_add_left (a / b) c b } r * (a % b) + r * ((a / b * b) + c * b); (==) { Math.Lemmas.d...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 119, "start_col": 0, "start_line": 106 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
r: Prims.int -> a: Prims.int -> c: Prims.int -> b: Prims.pos -> FStar.Pervasives.Lemma (ensures r * (a % b) + (r * (a / b + c)) * b = r * a + (r * c) * b)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "Prims.pos", "FStar.Calc.calc_finish", "Prims.eq2", "Prims.op_Addition", "FStar.Mul.op_Star", "Prims.op_Modulus", "Prims.op_Division", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", ...
[]
false
false
true
false
false
let lemma_distr_eucl_mul_add r a c b =
calc ( == ) { r * (a % b) + (r * (a / b + c)) * b; ( == ) { Math.Lemmas.paren_mul_right r (a / b + c) b } r * (a % b) + r * ((a / b + c) * b); ( == ) { Math.Lemmas.distributivity_add_left (a / b) c b } r * (a % b) + r * (((a / b) * b) + c * b); ( == ) { Math.Lemmas.distributivity_add_right r ((a / b) * b) (...
false
Vale.AES.AES_common_s.fst
Vale.AES.AES_common_s.aes_rcon
val aes_rcon (i: int) : nat32
val aes_rcon (i: int) : nat32
let aes_rcon (i:int) : nat32 = if i = 0 then 0x01 else if i = 1 then 0x02 else if i = 2 then 0x04 else if i = 3 then 0x08 else if i = 4 then 0x10 else if i = 5 then 0x20 else if i = 6 then 0x40 else if i = 7 then 0x80 else if i = 8 then 0x1b else 0x36
{ "file_name": "vale/specs/crypto/Vale.AES.AES_common_s.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 6, "end_line": 33, "start_col": 0, "start_line": 23 }
module Vale.AES.AES_common_s // IMPORTANT: This specification is written assuming a little-endian mapping from bytes to quad32s // This is explicit in key_schedule_to_round_keys when we construct the round_key rk, // but it also applies implicitly to the input quad32 open Vale.Def.Prop_s open Va...
{ "checked_file": "/", "dependencies": [ "Vale.Def.Words_s.fsti.checked", "Vale.Def.Words.Seq_s.fsti.checked", "Vale.Def.Words.Four_s.fsti.checked", "Vale.Def.Types_s.fst.checked", "Vale.Def.Prop_s.fst.checked", "Vale.Def.Opaque_s.fsti.checked", "prims.fst.checked", "FStar.Seq.fst.ch...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Seq", "short_module": null }, { "abbrev": false, "full_module": "Vale.Def.Types_s", "short_module": null }, { "abbrev": false, "full_module": "Vale....
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
i: Prims.int -> Vale.Def.Types_s.nat32
Prims.Tot
[ "total" ]
[]
[ "Prims.int", "Prims.op_Equality", "Prims.bool", "Vale.Def.Types_s.nat32" ]
[]
false
false
false
true
false
let aes_rcon (i: int) : nat32 =
if i = 0 then 0x01 else if i = 1 then 0x02 else if i = 2 then 0x04 else if i = 3 then 0x08 else if i = 4 then 0x10 else if i = 5 then 0x20 else if i = 6 then 0x40 else if i = 7 then 0x80 else if i = 8 then 0x1b else 0x36
false
Vale.AES.AES_common_s.fst
Vale.AES.AES_common_s.nb
val nb : Prims.int
let nb = 4
{ "file_name": "vale/specs/crypto/Vale.AES.AES_common_s.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 10, "end_line": 36, "start_col": 0, "start_line": 36 }
module Vale.AES.AES_common_s // IMPORTANT: This specification is written assuming a little-endian mapping from bytes to quad32s // This is explicit in key_schedule_to_round_keys when we construct the round_key rk, // but it also applies implicitly to the input quad32 open Vale.Def.Prop_s open Va...
{ "checked_file": "/", "dependencies": [ "Vale.Def.Words_s.fsti.checked", "Vale.Def.Words.Seq_s.fsti.checked", "Vale.Def.Words.Four_s.fsti.checked", "Vale.Def.Types_s.fst.checked", "Vale.Def.Prop_s.fst.checked", "Vale.Def.Opaque_s.fsti.checked", "prims.fst.checked", "FStar.Seq.fst.ch...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Seq", "short_module": null }, { "abbrev": false, "full_module": "Vale.Def.Types_s", "short_module": null }, { "abbrev": false, "full_module": "Vale....
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Prims.int
Prims.Tot
[ "total" ]
[]
[]
[]
false
false
false
true
false
let nb =
4
false
Vale.AES.AES_common_s.fst
Vale.AES.AES_common_s.is_aes_key
val is_aes_key (alg: algorithm) (s: seq nat8) : prop0
val is_aes_key (alg: algorithm) (s: seq nat8) : prop0
let is_aes_key (alg:algorithm) (s:seq nat8) : prop0 = length s == 4 * nk alg
{ "file_name": "vale/specs/crypto/Vale.AES.AES_common_s.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 76, "end_line": 52, "start_col": 0, "start_line": 52 }
module Vale.AES.AES_common_s // IMPORTANT: This specification is written assuming a little-endian mapping from bytes to quad32s // This is explicit in key_schedule_to_round_keys when we construct the round_key rk, // but it also applies implicitly to the input quad32 open Vale.Def.Prop_s open Va...
{ "checked_file": "/", "dependencies": [ "Vale.Def.Words_s.fsti.checked", "Vale.Def.Words.Seq_s.fsti.checked", "Vale.Def.Words.Four_s.fsti.checked", "Vale.Def.Types_s.fst.checked", "Vale.Def.Prop_s.fst.checked", "Vale.Def.Opaque_s.fsti.checked", "prims.fst.checked", "FStar.Seq.fst.ch...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Seq", "short_module": null }, { "abbrev": false, "full_module": "Vale.Def.Types_s", "short_module": null }, { "abbrev": false, "full_module": "Vale....
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
alg: Vale.AES.AES_common_s.algorithm -> s: FStar.Seq.Base.seq Vale.Def.Types_s.nat8 -> Vale.Def.Prop_s.prop0
Prims.Tot
[ "total" ]
[]
[ "Vale.AES.AES_common_s.algorithm", "FStar.Seq.Base.seq", "Vale.Def.Types_s.nat8", "Prims.eq2", "Prims.int", "FStar.Seq.Base.length", "FStar.Mul.op_Star", "Vale.AES.AES_common_s.nk", "Vale.Def.Prop_s.prop0" ]
[]
false
false
false
true
false
let is_aes_key (alg: algorithm) (s: seq nat8) : prop0 =
length s == 4 * nk alg
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_a_mul_c_plus_d_mod_e_mul_f_g
val lemma_a_mul_c_plus_d_mod_e_mul_f_g (a b c d f g:nat) : Lemma (requires c == g - b) (ensures a % pow2 b * pow2 c + (a / pow2 b + d * pow2 f) * pow2 g == a * pow2 c + d * pow2 (f + g))
val lemma_a_mul_c_plus_d_mod_e_mul_f_g (a b c d f g:nat) : Lemma (requires c == g - b) (ensures a % pow2 b * pow2 c + (a / pow2 b + d * pow2 f) * pow2 g == a * pow2 c + d * pow2 (f + g))
let lemma_a_mul_c_plus_d_mod_e_mul_f_g a b c d f g = calc (==) { a % pow2 b * pow2 c + (a / pow2 b + d * pow2 f) * pow2 g; (==) { lemma_distr_pow (a / pow2 b) d f g } a % pow2 b * pow2 c + (a / pow2 b) * pow2 (c + b) + d * pow2 (f + g); (==) { lemma_distr_pow (a % pow2 b) (a / pow2 b) b c } (a % p...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 292, "start_col": 0, "start_line": 283 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.nat -> b: Prims.nat -> c: Prims.nat -> d: Prims.nat -> f: Prims.nat -> g: Prims.nat -> FStar.Pervasives.Lemma (requires c == g - b) (ensures (a % Prims.pow2 b) * Prims.pow2 c + (a / Prims.pow2 b + d * Prims.pow2 f) * Prims.pow2 g == a * Prims.pow2 c + d * Prims.pow2 (f + g))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Calc.calc_finish", "Prims.int", "Prims.eq2", "Prims.op_Addition", "FStar.Mul.op_Star", "Prims.op_Modulus", "Prims.pow2", "Prims.op_Division", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.C...
[]
false
false
true
false
false
let lemma_a_mul_c_plus_d_mod_e_mul_f_g a b c d f g =
calc ( == ) { (a % pow2 b) * pow2 c + (a / pow2 b + d * pow2 f) * pow2 g; ( == ) { lemma_distr_pow (a / pow2 b) d f g } (a % pow2 b) * pow2 c + (a / pow2 b) * pow2 (c + b) + d * pow2 (f + g); ( == ) { lemma_distr_pow (a % pow2 b) (a / pow2 b) b c } (a % pow2 b + (a / pow2 b) * pow2 b) * pow2 c + d * pow2 (f +...
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_a_mod_52_mul_b
val lemma_a_mod_52_mul_b (a b:nat) : Lemma ((a % pow2 52) * pow2 b = a * pow2 b - a / pow2 52 * pow2 (b + 52))
val lemma_a_mod_52_mul_b (a b:nat) : Lemma ((a % pow2 52) * pow2 b = a * pow2 b - a / pow2 52 * pow2 (b + 52))
let lemma_a_mod_52_mul_b a b = calc (==) { (a % pow2 52) * pow2 b; (==) { Math.Lemmas.euclidean_division_definition a (pow2 52) } (a - a / pow2 52 * pow2 52) * pow2 b; (==) { Math.Lemmas.distributivity_sub_left a (a / pow2 52 * pow2 52) (pow2 b) } a * pow2 b - a / pow2 52 * pow2 52 * pow2 b; (...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 307, "start_col": 0, "start_line": 298 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Prims.nat -> b: Prims.nat -> FStar.Pervasives.Lemma (ensures (a % Prims.pow2 52) * Prims.pow2 b = a * Prims.pow2 b - (a / Prims.pow2 52) * Prims.pow2 (b + 52))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Calc.calc_finish", "Prims.int", "Prims.eq2", "FStar.Mul.op_Star", "Prims.op_Modulus", "Prims.pow2", "Prims.op_Subtraction", "Prims.op_Division", "Prims.op_Addition", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.C...
[]
false
false
true
false
false
let lemma_a_mod_52_mul_b a b =
calc ( == ) { (a % pow2 52) * pow2 b; ( == ) { Math.Lemmas.euclidean_division_definition a (pow2 52) } (a - (a / pow2 52) * pow2 52) * pow2 b; ( == ) { Math.Lemmas.distributivity_sub_left a ((a / pow2 52) * pow2 52) (pow2 b) } a * pow2 b - ((a / pow2 52) * pow2 52) * pow2 b; ( == ) { (Math.Lemmas.paren_mul_...
false
GEXN.fst
GEXN.exn
val exn : Prims.eqtype
let exn = string
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 16, "end_line": 25, "start_col": 0, "start_line": 25 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Prims.eqtype
Prims.Tot
[ "total" ]
[]
[ "Prims.string" ]
[]
false
false
false
true
false
let exn =
string
false
GEXN.fst
GEXN.gex'
val gex' : a: Type -> Type
let gex' (a:Type) = unit -> M (s:set exn & (either a (e:exn{mem e s})))
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 71, "end_line": 31, "start_col": 0, "start_line": 31 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> Type
Prims.Tot
[ "total" ]
[]
[ "Prims.unit", "Prims.dtuple2", "FStar.Set.set", "GEXN.exn", "FStar.Pervasives.either", "Prims.b2t", "FStar.Set.mem" ]
[]
false
false
false
true
true
let gex' (a: Type) =
unit -> M (s: set exn & (either a (e: exn{mem e s})))
false
GEXN.fst
GEXN.gex
val gex : a: Type -> Type
let gex (a:Type) = unit -> M ((set exn) * either a exn)
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 55, "end_line": 27, "start_col": 0, "start_line": 27 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> Type
Prims.Tot
[ "total" ]
[]
[ "Prims.unit", "FStar.Pervasives.Native.tuple2", "FStar.Set.set", "GEXN.exn", "FStar.Pervasives.either" ]
[]
false
false
false
true
true
let gex (a: Type) =
unit -> M ((set exn) * either a exn)
false
GEXN.fst
GEXN.return_gex
val return_gex : (a:Type) -> (x:a) -> gex a
val return_gex : (a:Type) -> (x:a) -> gex a
let return_gex a x = fun _ -> empty , Inl x
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 43, "end_line": 35, "start_col": 0, "start_line": 35 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> x: a -> GEXN.gex a
Prims.Tot
[ "total" ]
[]
[ "Prims.unit", "FStar.Pervasives.Native.Mktuple2", "FStar.Set.set", "GEXN.exn", "FStar.Pervasives.either", "FStar.Set.empty", "FStar.Pervasives.Inl", "FStar.Pervasives.Native.tuple2" ]
[]
false
false
false
true
false
let return_gex a x =
fun _ -> empty, Inl x
false
GEXN.fst
GEXN.raise0
val raise0 (a: Type) (e: exn) : gex a
val raise0 (a: Type) (e: exn) : gex a
let raise0 (a:Type) (e:exn) : gex a = fun _ -> singleton e , Inr e
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 66, "end_line": 44, "start_col": 0, "start_line": 44 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> e: GEXN.exn -> GEXN.gex a
Prims.Tot
[ "total" ]
[]
[ "GEXN.exn", "Prims.unit", "FStar.Pervasives.Native.Mktuple2", "FStar.Set.set", "FStar.Pervasives.either", "FStar.Set.singleton", "FStar.Pervasives.Inr", "FStar.Pervasives.Native.tuple2", "GEXN.gex" ]
[]
false
false
false
true
false
let raise0 (a: Type) (e: exn) : gex a =
fun _ -> singleton e, Inr e
false
GEXN.fst
GEXN.exn_wp
val exn_wp : a: Type -> Type
let exn_wp (a:Type) = (either a exn -> Type0) -> Type0
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 55, "end_line": 58, "start_col": 0, "start_line": 58 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> Type
Prims.Tot
[ "total" ]
[]
[ "FStar.Pervasives.either", "GEXN.exn" ]
[]
false
false
false
true
true
let exn_wp (a: Type) =
(either a exn -> Type0) -> Type0
false
GEXN.fst
GEXN.gexn_wp
val gexn_wp : a: Type -> Type
let gexn_wp (a:Type) = unit -> (set exn * either a exn -> Type0) -> Type0
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 73, "end_line": 57, "start_col": 0, "start_line": 57 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> Type
Prims.Tot
[ "total" ]
[]
[ "Prims.unit", "FStar.Pervasives.Native.tuple2", "FStar.Set.set", "GEXN.exn", "FStar.Pervasives.either" ]
[]
false
false
false
true
true
let gexn_wp (a: Type) =
unit -> ((set exn * either a exn) -> Type0) -> Type0
false
Vale.AES.AES_common_s.fst
Vale.AES.AES_common_s.nr
val nr : alg: Vale.AES.AES_common_s.algorithm -> Prims.int
let nr(alg:algorithm) = match alg with | AES_128 -> 10 | AES_192 -> 12 | AES_256 -> 14
{ "file_name": "vale/specs/crypto/Vale.AES.AES_common_s.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 17, "end_line": 50, "start_col": 7, "start_line": 46 }
module Vale.AES.AES_common_s // IMPORTANT: This specification is written assuming a little-endian mapping from bytes to quad32s // This is explicit in key_schedule_to_round_keys when we construct the round_key rk, // but it also applies implicitly to the input quad32 open Vale.Def.Prop_s open Va...
{ "checked_file": "/", "dependencies": [ "Vale.Def.Words_s.fsti.checked", "Vale.Def.Words.Seq_s.fsti.checked", "Vale.Def.Words.Four_s.fsti.checked", "Vale.Def.Types_s.fst.checked", "Vale.Def.Prop_s.fst.checked", "Vale.Def.Opaque_s.fsti.checked", "prims.fst.checked", "FStar.Seq.fst.ch...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Seq", "short_module": null }, { "abbrev": false, "full_module": "Vale.Def.Types_s", "short_module": null }, { "abbrev": false, "full_module": "Vale....
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
alg: Vale.AES.AES_common_s.algorithm -> Prims.int
Prims.Tot
[ "total" ]
[]
[ "Vale.AES.AES_common_s.algorithm", "Prims.int" ]
[]
false
false
false
true
false
let nr (alg: algorithm) =
match alg with | AES_128 -> 10 | AES_192 -> 12 | AES_256 -> 14
false
Huffman.fst
Huffman.leq_trie
val leq_trie (t1 t2: trie) : Tot bool
val leq_trie (t1 t2: trie) : Tot bool
let leq_trie (t1:trie) (t2:trie) : Tot bool = weight t1 <= weight t2
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 24, "end_line": 36, "start_col": 0, "start_line": 35 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t1: Huffman.trie -> t2: Huffman.trie -> Prims.bool
Prims.Tot
[ "total" ]
[]
[ "Huffman.trie", "Prims.op_LessThanOrEqual", "Huffman.weight", "Prims.bool" ]
[]
false
false
false
true
false
let leq_trie (t1 t2: trie) : Tot bool =
weight t1 <= weight t2
false
GEXN.fst
GEXN.bind_gex
val bind_gex : (a:Type) -> (b:Type) -> (f:gex a) -> (g:a -> gex b) -> gex b
val bind_gex : (a:Type) -> (b:Type) -> (f:gex a) -> (g:a -> gex b) -> gex b
let bind_gex a b f g = fun _ -> let (s,r) = f () in match r with | Inr e -> s , Inr e | Inl x -> g x ()
{ "file_name": "examples/indexed_effects/GEXN.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 19, "end_line": 42, "start_col": 0, "start_line": 38 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Set.fsti.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "GEXN.fst" }
[ { "abbrev": false, "full_module": "FStar.Set", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module": "FStar", ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
a: Type -> b: Type -> f: GEXN.gex a -> g: (g: a -> GEXN.gex b) -> GEXN.gex b
Prims.Tot
[ "total" ]
[]
[ "GEXN.gex", "Prims.unit", "FStar.Set.set", "GEXN.exn", "FStar.Pervasives.either", "FStar.Pervasives.Native.Mktuple2", "FStar.Pervasives.Inr", "FStar.Pervasives.Native.tuple2" ]
[]
false
false
false
true
false
let bind_gex a b f g =
fun _ -> let s, r = f () in match r with | Inr e -> s, Inr e | Inl x -> g x ()
false
BugWhileInv.fst
BugWhileInv.workaround
val workaround (b: bool) (v: nat) : vprop
val workaround (b: bool) (v: nat) : vprop
let workaround (b:bool) (v:nat) : vprop = pure (not b ==> v == 0)
{ "file_name": "share/steel/examples/pulse/bug-reports/BugWhileInv.fst", "git_rev": "f984200f79bdc452374ae994a5ca837496476c41", "git_url": "https://github.com/FStarLang/steel.git", "project_name": "steel" }
{ "end_col": 27, "end_line": 21, "start_col": 0, "start_line": 20 }
(* Copyright 2023 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "checked_file": "/", "dependencies": [ "Pulse.Lib.Pervasives.fst.checked", "prims.fst.checked", "FStar.Pervasives.fsti.checked" ], "interface_file": false, "source_file": "BugWhileInv.fst" }
[ { "abbrev": false, "full_module": "Pulse.Lib.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": "Prims", "short_module": null }, { "abbrev": false, "full_module":...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
b: Prims.bool -> v: Prims.nat -> Pulse.Lib.Core.vprop
Prims.Tot
[ "total" ]
[]
[ "Prims.bool", "Prims.nat", "Pulse.Lib.Core.pure", "Prims.l_imp", "Prims.b2t", "Prims.op_Negation", "Prims.eq2", "Prims.int", "Pulse.Lib.Core.vprop" ]
[]
false
false
false
true
false
let workaround (b: bool) (v: nat) : vprop =
pure (not b ==> v == 0)
false
Vale.AES.AES_common_s.fst
Vale.AES.AES_common_s.nk
val nk : alg: Vale.AES.AES_common_s.algorithm -> Prims.int
let nk(alg:algorithm) = match alg with | AES_128 -> 4 | AES_192 -> 6 | AES_256 -> 8
{ "file_name": "vale/specs/crypto/Vale.AES.AES_common_s.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 16, "end_line": 43, "start_col": 7, "start_line": 39 }
module Vale.AES.AES_common_s // IMPORTANT: This specification is written assuming a little-endian mapping from bytes to quad32s // This is explicit in key_schedule_to_round_keys when we construct the round_key rk, // but it also applies implicitly to the input quad32 open Vale.Def.Prop_s open Va...
{ "checked_file": "/", "dependencies": [ "Vale.Def.Words_s.fsti.checked", "Vale.Def.Words.Seq_s.fsti.checked", "Vale.Def.Words.Four_s.fsti.checked", "Vale.Def.Types_s.fst.checked", "Vale.Def.Prop_s.fst.checked", "Vale.Def.Opaque_s.fsti.checked", "prims.fst.checked", "FStar.Seq.fst.ch...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "FStar.Seq", "short_module": null }, { "abbrev": false, "full_module": "Vale.Def.Types_s", "short_module": null }, { "abbrev": false, "full_module": "Vale....
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 0, "max_fuel": 1, "max_ifuel": 1, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
alg: Vale.AES.AES_common_s.algorithm -> Prims.int
Prims.Tot
[ "total" ]
[]
[ "Vale.AES.AES_common_s.algorithm", "Prims.int" ]
[]
false
false
false
true
false
let nk (alg: algorithm) =
match alg with | AES_128 -> 4 | AES_192 -> 6 | AES_256 -> 8
false
Huffman.fst
Huffman.sorted
val sorted (ts: list trie) : Tot bool
val sorted (ts: list trie) : Tot bool
let rec sorted (ts:list trie) : Tot bool = match ts with | [] | [_] -> true | t1::t2::ts' -> leq_trie t1 t2 && sorted (t2::ts')
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 53, "end_line": 44, "start_col": 0, "start_line": 41 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
ts: Prims.list Huffman.trie -> Prims.bool
Prims.Tot
[ "total" ]
[]
[ "Prims.list", "Huffman.trie", "Prims.op_AmpAmp", "Huffman.leq_trie", "Huffman.sorted", "Prims.Cons", "Prims.bool" ]
[ "recursion" ]
false
false
false
true
false
let rec sorted (ts: list trie) : Tot bool =
match ts with | [] | [_] -> true | t1 :: t2 :: ts' -> leq_trie t1 t2 && sorted (t2 :: ts')
false
Hacl.Bignum25519.fsti
Hacl.Bignum25519.felem
val felem : Type0
let felem = lbuffer uint64 5ul
{ "file_name": "code/ed25519/Hacl.Bignum25519.fsti", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 30, "end_line": 19, "start_col": 0, "start_line": 19 }
module Hacl.Bignum25519 module ST = FStar.HyperStack.ST open FStar.HyperStack.All open Lib.IntTypes open Lib.Buffer module BSeq = Lib.ByteSequence module S51 = Hacl.Spec.Curve25519.Field51.Definition module F51 = Hacl.Impl.Ed25519.Field51 module SC = Spec.Curve25519 #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" ...
{ "checked_file": "/", "dependencies": [ "Spec.Ed25519.fst.checked", "Spec.Curve25519.fst.checked", "prims.fst.checked", "Lib.IntTypes.fsti.checked", "Lib.ByteSequence.fsti.checked", "Lib.Buffer.fsti.checked", "Hacl.Spec.Curve25519.Finv.fst.checked", "Hacl.Spec.Curve25519.Field51.Def...
[ { "abbrev": true, "full_module": "Spec.Curve25519", "short_module": "SC" }, { "abbrev": true, "full_module": "Hacl.Impl.Ed25519.Field51", "short_module": "F51" }, { "abbrev": true, "full_module": "Hacl.Spec.Curve25519.Field51.Definition", "short_module": "S51" }, { ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Type0
Prims.Tot
[ "total" ]
[]
[ "Lib.Buffer.lbuffer", "Lib.IntTypes.uint64", "FStar.UInt32.__uint_to_t" ]
[]
false
false
false
true
true
let felem =
lbuffer uint64 5ul
false
Hacl.Bignum25519.fsti
Hacl.Bignum25519.point
val point : Type0
let point = lbuffer uint64 20ul
{ "file_name": "code/ed25519/Hacl.Bignum25519.fsti", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 31, "end_line": 23, "start_col": 0, "start_line": 23 }
module Hacl.Bignum25519 module ST = FStar.HyperStack.ST open FStar.HyperStack.All open Lib.IntTypes open Lib.Buffer module BSeq = Lib.ByteSequence module S51 = Hacl.Spec.Curve25519.Field51.Definition module F51 = Hacl.Impl.Ed25519.Field51 module SC = Spec.Curve25519 #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" ...
{ "checked_file": "/", "dependencies": [ "Spec.Ed25519.fst.checked", "Spec.Curve25519.fst.checked", "prims.fst.checked", "Lib.IntTypes.fsti.checked", "Lib.ByteSequence.fsti.checked", "Lib.Buffer.fsti.checked", "Hacl.Spec.Curve25519.Finv.fst.checked", "Hacl.Spec.Curve25519.Field51.Def...
[ { "abbrev": true, "full_module": "Spec.Curve25519", "short_module": "SC" }, { "abbrev": true, "full_module": "Hacl.Impl.Ed25519.Field51", "short_module": "F51" }, { "abbrev": true, "full_module": "Hacl.Spec.Curve25519.Field51.Definition", "short_module": "S51" }, { ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
Type0
Prims.Tot
[ "total" ]
[]
[ "Lib.Buffer.lbuffer", "Lib.IntTypes.uint64", "FStar.UInt32.__uint_to_t" ]
[]
false
false
false
true
true
let point =
lbuffer uint64 20ul
false
Huffman.fst
Huffman.weight
val weight (t: trie) : Tot pos
val weight (t: trie) : Tot pos
let weight (t:trie) : Tot pos = match t with | Leaf w _ -> w | Node w _ _ -> w
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 19, "end_line": 33, "start_col": 0, "start_line": 30 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> Prims.pos
Prims.Tot
[ "total" ]
[]
[ "Huffman.trie", "Prims.pos", "Huffman.symbol" ]
[]
false
false
false
true
false
let weight (t: trie) : Tot pos =
match t with | Leaf w _ -> w | Node w _ _ -> w
false
Huffman.fst
Huffman.insert_in_sorted
val insert_in_sorted (x: trie) (xs: list trie) : Pure (list trie) (requires (b2t (sorted xs))) (ensures (fun ys -> sorted ys /\ permutation (x :: xs) ys))
val insert_in_sorted (x: trie) (xs: list trie) : Pure (list trie) (requires (b2t (sorted xs))) (ensures (fun ys -> sorted ys /\ permutation (x :: xs) ys))
let rec insert_in_sorted (x:trie) (xs:list trie) : Pure (list trie) (requires (b2t (sorted xs))) (ensures (fun ys -> sorted ys /\ permutation (x::xs) ys)) = match xs with | [] -> [x] | x'::xs' -> if leq_trie x x' then x :: xs else (let i_tl = insert_in_sorted x xs' in l...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 32, "end_line": 67, "start_col": 0, "start_line": 59 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
x: Huffman.trie -> xs: Prims.list Huffman.trie -> Prims.Pure (Prims.list Huffman.trie)
Prims.Pure
[]
[]
[ "Huffman.trie", "Prims.list", "Prims.Cons", "Prims.Nil", "Huffman.leq_trie", "Prims.bool", "Huffman.insert_in_sorted", "Prims.b2t", "Huffman.sorted", "Prims.l_and", "Huffman.permutation" ]
[ "recursion" ]
false
false
false
false
false
let rec insert_in_sorted (x: trie) (xs: list trie) : Pure (list trie) (requires (b2t (sorted xs))) (ensures (fun ys -> sorted ys /\ permutation (x :: xs) ys)) =
match xs with | [] -> [x] | x' :: xs' -> if leq_trie x x' then x :: xs else (let i_tl = insert_in_sorted x xs' in let z :: _ = i_tl in x' :: i_tl)
false
Huffman.fst
Huffman.encode_one
val encode_one (t: trie) (s: symbol) : Tot (option (list bool))
val encode_one (t: trie) (s: symbol) : Tot (option (list bool))
let rec encode_one (t:trie) (s:symbol) : Tot (option (list bool)) = match t with | Leaf _ s' -> if s = s' then Some [] else None | Node _ t1 t2 -> match encode_one t1 s with | Some bs -> Some (false :: bs) | None -> match encode_one t2 s with | Some bs -> Some (true :: bs) ...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 30, "end_line": 112, "start_col": 0, "start_line": 104 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> s: Huffman.symbol -> FStar.Pervasives.Native.option (Prims.list Prims.bool)
Prims.Tot
[ "total" ]
[]
[ "Huffman.trie", "Huffman.symbol", "Prims.pos", "Prims.op_Equality", "FStar.Pervasives.Native.Some", "Prims.list", "Prims.bool", "Prims.Nil", "FStar.Pervasives.Native.None", "FStar.Pervasives.Native.option", "Huffman.encode_one", "Prims.Cons" ]
[ "recursion" ]
false
false
false
true
false
let rec encode_one (t: trie) (s: symbol) : Tot (option (list bool)) =
match t with | Leaf _ s' -> if s = s' then Some [] else None | Node _ t1 t2 -> match encode_one t1 s with | Some bs -> Some (false :: bs) | None -> match encode_one t2 s with | Some bs -> Some (true :: bs) | None -> None
false
StatefulLens.fst
StatefulLens.compose_hlens
val compose_hlens (#a #b #c: _) (l: hlens a b) (m: hlens b c) : hlens a c
val compose_hlens (#a #b #c: _) (l: hlens a b) (m: hlens b c) : hlens a c
let compose_hlens #a #b #c (l:hlens a b) (m:hlens b c) : hlens a c = { get = (fun (h0, x) -> m.get (h0, l.get (h0, x))); put = (fun (z:c) (h0, x) -> let h1, b = m.put z (h0, (l.get (h0, x))) in l.put b (h1, x)) }
{ "file_name": "examples/data_structures/StatefulLens.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 1, "end_line": 53, "start_col": 0, "start_line": 50 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Lens.fst.checked", "FStar.Ref.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Heap.fst.checked" ], "interface_file": false, "source_file": "StatefulLens.fst" }
[ { "abbrev": false, "full_module": "Lens // Pure lenses", "short_module": null }, { "abbrev": false, "full_module": "FStar.Ref", "short_module": null }, { "abbrev": false, "full_module": "FStar.Heap", "short_module": null }, { "abbrev": false, "full_module": "L...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
l: StatefulLens.hlens a b -> m: StatefulLens.hlens b c -> StatefulLens.hlens a c
Prims.Tot
[ "total" ]
[]
[ "StatefulLens.hlens", "StatefulLens.Mkhlens", "FStar.Pervasives.Native.tuple2", "FStar.Monotonic.Heap.heap", "StatefulLens.__proj__Mkhlens__item__get", "FStar.Pervasives.Native.Mktuple2", "StatefulLens.__proj__Mkhlens__item__put" ]
[]
false
false
false
true
false
let compose_hlens #a #b #c (l: hlens a b) (m: hlens b c) : hlens a c =
{ get = (fun (h0, x) -> m.get (h0, l.get (h0, x))); put = (fun (z: c) (h0, x) -> let h1, b = m.put z (h0, (l.get (h0, x))) in l.put b (h1, x)) }
false
StatefulLens.fst
StatefulLens.as_hlens
val as_hlens (l: lens 'a 'b) : hlens 'a 'b
val as_hlens (l: lens 'a 'b) : hlens 'a 'b
let as_hlens (l:lens 'a 'b) : hlens 'a 'b = { get = (fun (h, x) -> x.[l]); put = (fun y (h, x) -> h, (x.[l] <- y)); }
{ "file_name": "examples/data_structures/StatefulLens.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 1, "end_line": 47, "start_col": 0, "start_line": 44 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "Lens.fst.checked", "FStar.Ref.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Heap.fst.checked" ], "interface_file": false, "source_file": "StatefulLens.fst" }
[ { "abbrev": false, "full_module": "Lens // Pure lenses", "short_module": null }, { "abbrev": false, "full_module": "FStar.Ref", "short_module": null }, { "abbrev": false, "full_module": "FStar.Heap", "short_module": null }, { "abbrev": false, "full_module": "L...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
l: Lens.lens 'a 'b -> StatefulLens.hlens 'a 'b
Prims.Tot
[ "total" ]
[]
[ "Lens.lens", "StatefulLens.Mkhlens", "FStar.Pervasives.Native.tuple2", "FStar.Monotonic.Heap.heap", "Lens.op_String_Access", "FStar.Pervasives.Native.Mktuple2", "Lens.op_String_Assignment", "StatefulLens.hlens" ]
[]
false
false
false
true
false
let as_hlens (l: lens 'a 'b) : hlens 'a 'b =
{ get = (fun (h, x) -> x.[ l ]); put = (fun y (h, x) -> h, (x.[ l ] <- y)) }
false
Huffman.fst
Huffman.sorted_smaller
val sorted_smaller: x:trie -> y:trie -> l:list trie -> Lemma (requires (sorted (x::l) /\ mem y l)) (ensures (leq_trie x y)) [SMTPat (sorted (x::l)); SMTPat (mem y l)]
val sorted_smaller: x:trie -> y:trie -> l:list trie -> Lemma (requires (sorted (x::l) /\ mem y l)) (ensures (leq_trie x y)) [SMTPat (sorted (x::l)); SMTPat (mem y l)]
let rec sorted_smaller x y l = match l with | [] -> () | z::zs -> if z=y then () else sorted_smaller x y zs
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 56, "end_line": 57, "start_col": 0, "start_line": 55 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
x: Huffman.trie -> y: Huffman.trie -> l: Prims.list Huffman.trie -> FStar.Pervasives.Lemma (requires Huffman.sorted (x :: l) /\ FStar.List.Tot.Base.mem y l) (ensures Huffman.leq_trie x y) [SMTPat (Huffman.sorted (x :: l)); SMTPat (FStar.List.Tot.Base.mem y l)]
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Huffman.trie", "Prims.list", "Prims.op_Equality", "Prims.bool", "Huffman.sorted_smaller", "Prims.unit" ]
[ "recursion" ]
false
false
true
false
false
let rec sorted_smaller x y l =
match l with | [] -> () | z :: zs -> if z = y then () else sorted_smaller x y zs
false
Huffman.fst
Huffman.decode
val decode (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (b2t (Node? t))) (ensures (fun _ -> True))
val decode (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (b2t (Node? t))) (ensures (fun _ -> True))
let decode (t:trie) (bs:list bool) : Pure (option (list symbol)) (requires (b2t (Node? t))) (ensures (fun _ -> True)) = decode_aux t t bs
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 19, "end_line": 169, "start_col": 0, "start_line": 167 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> bs: Prims.list Prims.bool -> Prims.Pure (FStar.Pervasives.Native.option (Prims.list Huffman.symbol))
Prims.Pure
[]
[]
[ "Huffman.trie", "Prims.list", "Prims.bool", "Huffman.decode_aux", "FStar.Pervasives.Native.option", "Huffman.symbol", "Prims.b2t", "Huffman.uu___is_Node", "Prims.l_True" ]
[]
false
false
false
false
false
let decode (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (b2t (Node? t))) (ensures (fun _ -> True)) =
decode_aux t t bs
false
Huffman.fst
Huffman.insertion_sort
val insertion_sort (ts: list trie) : Pure (list trie) (requires (True)) (ensures (fun ts' -> sorted ts' /\ permutation ts ts'))
val insertion_sort (ts: list trie) : Pure (list trie) (requires (True)) (ensures (fun ts' -> sorted ts' /\ permutation ts ts'))
let rec insertion_sort (ts : list trie) : Pure (list trie) (requires (True)) (ensures (fun ts' -> sorted ts' /\ permutation ts ts')) = match ts with | [] -> [] | t::ts' -> insert_in_sorted t (insertion_sort ts')
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 53, "end_line": 73, "start_col": 0, "start_line": 69 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
ts: Prims.list Huffman.trie -> Prims.Pure (Prims.list Huffman.trie)
Prims.Pure
[]
[]
[ "Prims.list", "Huffman.trie", "Prims.Nil", "Huffman.insert_in_sorted", "Huffman.insertion_sort", "Prims.l_True", "Prims.l_and", "Prims.b2t", "Huffman.sorted", "Huffman.permutation" ]
[ "recursion" ]
false
false
false
false
false
let rec insertion_sort (ts: list trie) : Pure (list trie) (requires (True)) (ensures (fun ts' -> sorted ts' /\ permutation ts ts')) =
match ts with | [] -> [] | t :: ts' -> insert_in_sorted t (insertion_sort ts')
false
Huffman.fst
Huffman.huffman_trie
val huffman_trie (ts: list trie) : Pure trie (requires (sorted ts /\ List.Tot.length ts > 0)) (ensures (fun t -> ((List.Tot.length ts > 1 \/ existsb Node? ts) ==> Node? t))) (decreases (List.Tot.length ts))
val huffman_trie (ts: list trie) : Pure trie (requires (sorted ts /\ List.Tot.length ts > 0)) (ensures (fun t -> ((List.Tot.length ts > 1 \/ existsb Node? ts) ==> Node? t))) (decreases (List.Tot.length ts))
let rec huffman_trie (ts:list trie) : Pure trie (requires (sorted ts /\ List.Tot.length ts > 0)) (ensures (fun t -> ((List.Tot.length ts > 1 \/ existsb Node? ts) ==> Node? t))) (decreases (List.Tot.length ts)) = match ts with | t1::t2::ts' -> assert(List.Tot.length ts > 1); (* so it needs to...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 14, "end_line": 97, "start_col": 0, "start_line": 75 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
ts: Prims.list Huffman.trie -> Prims.Pure Huffman.trie
Prims.Pure
[ "" ]
[]
[ "Prims.list", "Huffman.trie", "Prims.unit", "Prims._assert", "Prims.b2t", "Huffman.uu___is_Node", "Prims.uu___is_Nil", "FStar.List.Tot.Base.existsb", "Huffman.insert_in_sorted", "Huffman.Node", "Prims.bool", "Prims.op_GreaterThan", "FStar.List.Tot.Base.length", "Huffman.huffman_trie", "P...
[ "recursion" ]
false
false
false
false
false
let rec huffman_trie (ts: list trie) : Pure trie (requires (sorted ts /\ List.Tot.length ts > 0)) (ensures (fun t -> ((List.Tot.length ts > 1 \/ existsb Node? ts) ==> Node? t))) (decreases (List.Tot.length ts)) =
match ts with | t1 :: t2 :: ts' -> assert (List.Tot.length ts > 1); let w = weight t1 + weight t2 in let t = huffman_trie ((Node w t1 t2) `insert_in_sorted` ts') in if Nil? ts' then assert (existsb Node? ((Node w t1 t2) `insert_in_sorted` ts')) else assert (length ((Node w t1 t2) `insert_in_sorted` ts') > 1...
false
Huffman.fst
Huffman.encode
val encode (t: trie) (ss: list symbol) : Pure (option (list bool)) (requires (True)) (ensures (fun bs -> Node? t /\ Cons? ss /\ Some? bs ==> Cons? (Some?.v bs)))
val encode (t: trie) (ss: list symbol) : Pure (option (list bool)) (requires (True)) (ensures (fun bs -> Node? t /\ Cons? ss /\ Some? bs ==> Cons? (Some?.v bs)))
let rec encode (t:trie) (ss:list symbol) : Pure (option (list bool)) (requires (True)) (ensures (fun bs -> Node? t /\ Cons? ss /\ Some? bs ==> Cons? (Some?.v bs))) = match ss with | [] -> None (* can't encode the empty string *) | [s] -> encode_one t s | s::ss' -> match encode_on...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 28, "end_line": 124, "start_col": 0, "start_line": 115 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> ss: Prims.list Huffman.symbol -> Prims.Pure (FStar.Pervasives.Native.option (Prims.list Prims.bool))
Prims.Pure
[]
[]
[ "Huffman.trie", "Prims.list", "Huffman.symbol", "FStar.Pervasives.Native.None", "Prims.bool", "Huffman.encode_one", "FStar.Pervasives.Native.Mktuple2", "FStar.Pervasives.Native.option", "Huffman.encode", "FStar.Pervasives.Native.Some", "FStar.List.Tot.Base.op_At", "Prims.l_True", "Prims.l_im...
[ "recursion" ]
false
false
false
false
false
let rec encode (t: trie) (ss: list symbol) : Pure (option (list bool)) (requires (True)) (ensures (fun bs -> Node? t /\ Cons? ss /\ Some? bs ==> Cons? (Some?.v bs))) =
match ss with | [] -> None | [s] -> encode_one t s | s :: ss' -> match encode_one t s, encode t ss' with | Some bs, Some bs' -> Some (bs @ bs') | _, _ -> None
false
Huffman.fst
Huffman.decode_one
val decode_one (t: trie) (bs: list bool) : Pure (option (symbol * list bool)) (requires (True)) (ensures (fun r -> Some? r ==> (List.Tot.length (snd (Some?.v r)) <= List.Tot.length bs /\ (Node? t ==> List.Tot.length (snd (Some?.v r)) < List.Tot.length bs))))
val decode_one (t: trie) (bs: list bool) : Pure (option (symbol * list bool)) (requires (True)) (ensures (fun r -> Some? r ==> (List.Tot.length (snd (Some?.v r)) <= List.Tot.length bs /\ (Node? t ==> List.Tot.length (snd (Some?.v r)) < List.Tot.length bs))))
let rec decode_one (t:trie) (bs:list bool) : Pure (option (symbol * list bool)) (requires (True)) (ensures (fun r -> Some? r ==> (List.Tot.length (snd (Some?.v r)) <= List.Tot.length bs /\ (Node? t ==> List.Tot.length (snd (Some?.v r)) < List.Tot.length bs)))) = match t, bs with | No...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 26, "end_line": 136, "start_col": 0, "start_line": 128 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> bs: Prims.list Prims.bool -> Prims.Pure (FStar.Pervasives.Native.option (Huffman.symbol * Prims.list Prims.bool))
Prims.Pure
[]
[]
[ "Huffman.trie", "Prims.list", "Prims.bool", "FStar.Pervasives.Native.Mktuple2", "Prims.pos", "Huffman.decode_one", "Huffman.symbol", "FStar.Pervasives.Native.Some", "FStar.Pervasives.Native.tuple2", "FStar.Pervasives.Native.None", "FStar.Pervasives.Native.option", "Prims.l_True", "Prims.l_im...
[ "recursion" ]
false
false
false
false
false
let rec decode_one (t: trie) (bs: list bool) : Pure (option (symbol * list bool)) (requires (True)) (ensures (fun r -> Some? r ==> (List.Tot.length (snd (Some?.v r)) <= List.Tot.length bs /\ (Node? t ==> List.Tot.length (snd (Some?.v r)) < List.Tot.length bs...
match t, bs with | Node _ t1 t2, b :: bs' -> decode_one (if b then t2 else t1) bs' | Leaf _ s, _ -> Some (s, bs) | Node _ _ _, [] -> None
false
Hacl.Spec.K256.MathLemmas.fst
Hacl.Spec.K256.MathLemmas.lemma_as_nat64_horner
val lemma_as_nat64_horner (r0 r1 r2 r3:int) : Lemma (r0 + r1 * pow2 64 + r2 * pow2 128 + r3 * pow2 192 == ((r3 * pow2 64 + r2) * pow2 64 + r1) * pow2 64 + r0)
val lemma_as_nat64_horner (r0 r1 r2 r3:int) : Lemma (r0 + r1 * pow2 64 + r2 * pow2 128 + r3 * pow2 192 == ((r3 * pow2 64 + r2) * pow2 64 + r1) * pow2 64 + r0)
let lemma_as_nat64_horner r0 r1 r2 r3 = calc (==) { r0 + pow2 64 * (r1 + pow2 64 * (r2 + pow2 64 * r3)); (==) { Math.Lemmas.swap_mul (pow2 64) (r1 + pow2 64 * (r2 + pow2 64 * r3)) } r0 + (r1 + pow2 64 * (r2 + pow2 64 * r3)) * pow2 64; (==) { Math.Lemmas.swap_mul (pow2 64) (r2 + pow2 64 * r3) } r0 ...
{ "file_name": "code/k256/Hacl.Spec.K256.MathLemmas.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 3, "end_line": 150, "start_col": 0, "start_line": 137 }
module Hacl.Spec.K256.MathLemmas open FStar.Mul #set-options "--z3rlimit 50 --fuel 0 --ifuel 0" val lemma_swap_mul3 (a b c:int) : Lemma (a * b * c == a * c * b) let lemma_swap_mul3 a b c = calc (==) { a * b * c; (==) { Math.Lemmas.paren_mul_right a b c } a * (b * c); (==) { Math.Lemmas.swap_mul b c...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst.checked", "FStar.Math.Lemmas.fst.checked", "FStar.Calc.fsti.checked" ], "interface_file": false, "source_file": "Hacl.Spec.K256.MathLemmas.fst" }
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "Hacl.Spec.K256", "short_module": null }, { "abbrev": false, "full_module": "FS...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 0, "initial_ifuel": 0, "max_fuel": 0, "max_ifuel": 0, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
r0: Prims.int -> r1: Prims.int -> r2: Prims.int -> r3: Prims.int -> FStar.Pervasives.Lemma (ensures r0 + r1 * Prims.pow2 64 + r2 * Prims.pow2 128 + r3 * Prims.pow2 192 == ((r3 * Prims.pow2 64 + r2) * Prims.pow2 64 + r1) * Prims.pow2 64 + r0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.int", "FStar.Calc.calc_finish", "Prims.eq2", "Prims.op_Addition", "FStar.Mul.op_Star", "Prims.pow2", "Prims.Cons", "FStar.Preorder.relation", "Prims.Nil", "Prims.unit", "FStar.Calc.calc_step", "FStar.Calc.calc_init", "FStar.Calc.calc_pack", "FStar.Math.Lemmas.swap_mul", "Prims.squ...
[]
false
false
true
false
false
let lemma_as_nat64_horner r0 r1 r2 r3 =
calc ( == ) { r0 + pow2 64 * (r1 + pow2 64 * (r2 + pow2 64 * r3)); ( == ) { Math.Lemmas.swap_mul (pow2 64) (r1 + pow2 64 * (r2 + pow2 64 * r3)) } r0 + (r1 + pow2 64 * (r2 + pow2 64 * r3)) * pow2 64; ( == ) { Math.Lemmas.swap_mul (pow2 64) (r2 + pow2 64 * r3) } r0 + (r1 + (r2 + pow2 64 * r3) * pow2 64) * pow2 ...
false
Huffman.fst
Huffman.decode'
val decode' (t: trie) (bs: list bool) : Tot (option (list symbol)) (decreases (List.Tot.length bs))
val decode' (t: trie) (bs: list bool) : Tot (option (list symbol)) (decreases (List.Tot.length bs))
let rec decode' (t:trie) (bs:list bool) : Tot (option (list symbol)) (decreases (List.Tot.length bs)) = match t, bs with | Leaf _ s, [] -> Some [s] (* degenerate case, case omitted below *) | Leaf _ _, _::_ -> None (* too many symbols, case omitted below *) | Node _ _ _, [] -> Some [] | Node _ _ _, _::_ ...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 35, "end_line": 148, "start_col": 0, "start_line": 138 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t: Huffman.trie -> bs: Prims.list Prims.bool -> Prims.Tot (FStar.Pervasives.Native.option (Prims.list Huffman.symbol))
Prims.Tot
[ "total", "" ]
[]
[ "Huffman.trie", "Prims.list", "Prims.bool", "FStar.Pervasives.Native.Mktuple2", "Prims.pos", "Huffman.symbol", "FStar.Pervasives.Native.Some", "Prims.Cons", "Prims.Nil", "FStar.Pervasives.Native.None", "Huffman.decode_one", "Huffman.decode'", "FStar.Pervasives.Native.option", "FStar.Pervas...
[ "recursion" ]
false
false
false
true
false
let rec decode' (t: trie) (bs: list bool) : Tot (option (list symbol)) (decreases (List.Tot.length bs)) =
match t, bs with | Leaf _ s, [] -> Some [s] | Leaf _ _, _ :: _ -> None | Node _ _ _, [] -> Some [] | Node _ _ _, _ :: _ -> match decode_one t bs with | Some (s, bs') -> (match decode' t bs' with | Some ss -> Some (s :: ss) | None -> None) | _ -> None
false
Huffman.fst
Huffman.huffman
val huffman (sws: list (symbol * pos)) : Pure trie (requires (b2t (List.Tot.length sws > 0))) (ensures (fun t -> List.Tot.length sws > 1 ==> Node? t))
val huffman (sws: list (symbol * pos)) : Pure trie (requires (b2t (List.Tot.length sws > 0))) (ensures (fun t -> List.Tot.length sws > 1 ==> Node? t))
let huffman (sws:list (symbol*pos)) : Pure trie (requires (b2t (List.Tot.length sws > 0))) (ensures (fun t -> List.Tot.length sws > 1 ==> Node? t)) = huffman_trie (insertion_sort (List.Tot.map (fun (s,w) -> Leaf w s) sws))
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 74, "end_line": 102, "start_col": 0, "start_line": 99 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
sws: Prims.list (Huffman.symbol * Prims.pos) -> Prims.Pure Huffman.trie
Prims.Pure
[]
[]
[ "Prims.list", "FStar.Pervasives.Native.tuple2", "Huffman.symbol", "Prims.pos", "Huffman.huffman_trie", "Huffman.insertion_sort", "FStar.List.Tot.Base.map", "Huffman.trie", "Huffman.Leaf", "Prims.b2t", "Prims.op_GreaterThan", "FStar.List.Tot.Base.length", "Prims.l_imp", "Huffman.uu___is_Nod...
[]
false
false
false
false
false
let huffman (sws: list (symbol * pos)) : Pure trie (requires (b2t (List.Tot.length sws > 0))) (ensures (fun t -> List.Tot.length sws > 1 ==> Node? t)) =
huffman_trie (insertion_sort (List.Tot.map (fun (s, w) -> Leaf w s) sws))
false
Huffman.fst
Huffman.decode_aux
val decode_aux (t': trie{Node? t'}) (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (True)) (ensures (fun ss -> Some? ss ==> List.Tot.length (Some?.v ss) > 0)) (decreases (%[bs;if Leaf? t && Cons? bs then 1 else 0]))
val decode_aux (t': trie{Node? t'}) (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (True)) (ensures (fun ss -> Some? ss ==> List.Tot.length (Some?.v ss) > 0)) (decreases (%[bs;if Leaf? t && Cons? bs then 1 else 0]))
let rec decode_aux (t':trie{Node? t'}) (t:trie) (bs:list bool) : Pure (option (list symbol)) (requires (True)) (ensures (fun ss -> Some? ss ==> List.Tot.length (Some?.v ss) > 0)) (decreases (%[bs; if Leaf? t && Cons? bs then 1 else 0])) = match t, bs with | Leaf _ s, [] -> Some [s] | Leaf _ s, _::...
{ "file_name": "examples/algorithms/Huffman.fst", "git_rev": "10183ea187da8e8c426b799df6c825e24c0767d3", "git_url": "https://github.com/FStarLang/FStar.git", "project_name": "FStar" }
{ "end_col": 26, "end_line": 165, "start_col": 0, "start_line": 153 }
(* Copyright 2008-2018 Microsoft Research Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agre...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "FStar.Pervasives.Native.fst.checked", "FStar.Pervasives.fsti.checked", "FStar.List.Tot.fst.checked", "FStar.Char.fsti.checked" ], "interface_file": false, "source_file": "Huffman.fst" }
[ { "abbrev": false, "full_module": "FStar.List.Tot", "short_module": null }, { "abbrev": false, "full_module": "FStar.Char", "short_module": null }, { "abbrev": false, "full_module": "FStar.Pervasives", "short_module": null }, { "abbrev": false, "full_module": ...
{ "detail_errors": false, "detail_hint_replay": false, "initial_fuel": 2, "initial_ifuel": 1, "max_fuel": 8, "max_ifuel": 2, "no_plugins": false, "no_smt": false, "no_tactics": false, "quake_hi": 1, "quake_keep": false, "quake_lo": 1, "retry": false, "reuse_hint_for": null, "smtencoding_el...
false
t': Huffman.trie{Node? t'} -> t: Huffman.trie -> bs: Prims.list Prims.bool -> Prims.Pure (FStar.Pervasives.Native.option (Prims.list Huffman.symbol))
Prims.Pure
[ "" ]
[]
[ "Huffman.trie", "Prims.b2t", "Huffman.uu___is_Node", "Prims.list", "Prims.bool", "FStar.Pervasives.Native.Mktuple2", "Prims.pos", "Huffman.symbol", "FStar.Pervasives.Native.Some", "Prims.Cons", "Prims.Nil", "Huffman.decode_aux", "FStar.Pervasives.Native.None", "FStar.Pervasives.Native.opti...
[ "recursion" ]
false
false
false
false
false
let rec decode_aux (t': trie{Node? t'}) (t: trie) (bs: list bool) : Pure (option (list symbol)) (requires (True)) (ensures (fun ss -> Some? ss ==> List.Tot.length (Some?.v ss) > 0)) (decreases (%[bs;if Leaf? t && Cons? bs then 1 else 0])) =
match t, bs with | Leaf _ s, [] -> Some [s] | Leaf _ s, _ :: _ -> (match decode_aux t' t' bs with | Some ss -> Some (s :: ss) | None -> None) | Node _ t1 t2, b :: bs' -> decode_aux t' (if b then t2 else t1) bs' | Node _ _ _, [] -> None
false