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
LowParse.BitFields.fst
LowParse.BitFields.nth_pow2_minus_one
val nth_pow2_minus_one (#n: pos) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (nth #n (pow2 m - 1) i == (i < m))))
val nth_pow2_minus_one (#n: pos) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (nth #n (pow2 m - 1) i == (i < m))))
let nth_pow2_minus_one (#n:pos) (m:nat{m <= n}) (i:nat{i < n}) : Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (nth #n (pow2 m - 1) i == (i < m)))) = nth_pow2_minus_one' #n m (n - 1 - i)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 38, "end_line": 78, "start_col": 0, "start_line": 71 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
m: Prims.nat{m <= n} -> i: Prims.nat{i < n} -> FStar.Pervasives.Lemma (ensures Prims.pow2 m <= Prims.pow2 n /\ LowParse.BitFields.nth (Prims.pow2 m - 1) i == (i < m))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "LowParse.BitFields.nth_pow2_minus_one'", "Prims.op_Subtraction", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.l_and", "Prims.pow2", "Prims.eq2", "Prims.bool", "LowParse.BitFields.nth", "Pri...
[]
true
false
true
false
false
let nth_pow2_minus_one (#n: pos) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (nth #n (pow2 m - 1) i == (i < m)))) =
nth_pow2_minus_one' #n m (n - 1 - i)
false
LowParse.BitFields.fst
LowParse.BitFields.nth
val nth (#n: pos) (a: U.uint_t n) (i: nat{i < n}) : Tot bool
val nth (#n: pos) (a: U.uint_t n) (i: nat{i < n}) : Tot bool
let nth (#n: pos) (a: U.uint_t n) (i: nat {i < n}) : Tot bool = U.nth a (n - 1 - i)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 21, "end_line": 49, "start_col": 0, "start_line": 48 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t n -> i: Prims.nat{i < n} -> Prims.bool
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt.nth", "Prims.op_Subtraction", "Prims.bool" ]
[]
false
false
false
false
false
let nth (#n: pos) (a: U.uint_t n) (i: nat{i < n}) : Tot bool =
U.nth a (n - 1 - i)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask
val bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot)
val bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot)
let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2 (hi - lo) - 1) * pow2 lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 49, "end_line": 13, "start_col": 0, "start_line": 8 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.UInt.uint_t tot
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Pervasives.normalize_term", "FStar.UInt.uint_t", "FStar.Mul.op_Star", "Prims.op_Subtraction", "Prims.pow2", "Prims.unit", "FStar.Math.Lemmas.pow2_plus", "FStar.Math.Lemmas.pow2_le_compat" ]
[]
false
false
false
false
false
let bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot) =
[@@ inline_let ]let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2 (hi - lo) - 1) * pow2 lo)
false
LowParse.BitFields.fst
LowParse.BitFields.eq_nth
val eq_nth (#n: pos) (a b: U.uint_t n) (f: (i: nat{i < n} -> Lemma (nth a i == nth b i))) : Lemma (a == b)
val eq_nth (#n: pos) (a b: U.uint_t n) (f: (i: nat{i < n} -> Lemma (nth a i == nth b i))) : Lemma (a == b)
let eq_nth (#n: pos) (a: U.uint_t n) (b: U.uint_t n) (f: ( (i: nat { i < n }) -> Lemma (nth a i == nth b i) )) : Lemma (a == b) = let g (i: nat { i < n }) : Lemma (U.nth a i == U.nth b i) = f (n - 1 - i) in Classical.forall_intro g; U.nth_lemma a b
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 17, "end_line": 69, "start_col": 0, "start_line": 51 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t n -> b: FStar.UInt.uint_t n -> f: (i: Prims.nat{i < n} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth a i == LowParse.BitFields.nth b i)) -> FStar.Pervasives.Lemma (ensures a == b)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThan", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.bool", "LowParse.BitFields.nth", "Prims.Nil", "FStar.Pervasives.pattern", "FStar.UInt.nth_lemma", "FStar.Classical.forall_intro", "FStar.UI...
[]
false
false
true
false
false
let eq_nth (#n: pos) (a b: U.uint_t n) (f: (i: nat{i < n} -> Lemma (nth a i == nth b i))) : Lemma (a == b) =
let g (i: nat{i < n}) : Lemma (U.nth a i == U.nth b i) = f (n - 1 - i) in Classical.forall_intro g; U.nth_lemma a b
false
LowParse.BitFields.fst
LowParse.BitFields.nth_bitfield_mask
val nth_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (bitfield_mask tot lo hi) i == (lo <= i && i < hi))
val nth_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (bitfield_mask tot lo hi) i == (lo <= i && i < hi))
let nth_bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (i: nat {i < tot}) : Lemma (nth (bitfield_mask tot lo hi) i == (lo <= i && i < hi)) = bitfield_mask_eq tot lo hi; nth_shift_left #tot (pow2 (hi - lo) - 1) lo i; if i < lo then () else begin nth_pow2_minus_one #tot (...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 7, "end_line": 106, "start_col": 0, "start_line": 98 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth (LowParse.BitFields.bitfield_mask tot lo hi) i == (lo <= i && i < hi))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "Prims.bool", "LowParse.BitFields.nth_pow2_minus_one", "Prims.op_Subtraction", "Prims.unit", "LowParse.BitFields.nth_shift_left", "Prims.pow2", "LowParse.BitFields.bitfield_mask_eq", "Pri...
[]
false
false
true
false
false
let nth_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (bitfield_mask tot lo hi) i == (lo <= i && i < hi)) =
bitfield_mask_eq tot lo hi; nth_shift_left #tot (pow2 (hi - lo) - 1) lo i; if i < lo then () else nth_pow2_minus_one #tot (hi - lo) (i - lo)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_raw
val get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot)
val get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot)
let get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot) = (x `U.logand` bitfield_mask tot lo hi) `U.shift_right` lo
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 59, "end_line": 109, "start_col": 0, "start_line": 108 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.UInt.uint_t tot
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt.shift_right", "FStar.UInt.logand", "LowParse.BitFields.bitfield_mask" ]
[]
false
false
false
false
false
let get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (U.uint_t tot) =
(x `U.logand` (bitfield_mask tot lo hi)) `U.shift_right` lo
false
LowParse.BitFields.fst
LowParse.BitFields.nth_pow2_minus_one'
val nth_pow2_minus_one' : #n:pos -> m:nat{m <= n} -> i:nat{i < n} -> Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (i < n - m ==> U.nth #n (pow2 m - 1) i == false) /\ (n - m <= i ==> U.nth #n (pow2 m - 1) i == true)))
val nth_pow2_minus_one' : #n:pos -> m:nat{m <= n} -> i:nat{i < n} -> Lemma (requires True) (ensures (pow2 m <= pow2 n /\ (i < n - m ==> U.nth #n (pow2 m - 1) i == false) /\ (n - m <= i ==> U.nth #n (pow2 m - 1) i == true)))
let rec nth_pow2_minus_one' #n m i = let a = pow2 m - 1 in M.pow2_le_compat n m; if m = 0 then U.one_to_vec_lemma #n i else if m = n then U.ones_to_vec_lemma #n i else if i = n - 1 then () else nth_pow2_minus_one' #(n - 1) (m - 1) i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 46, "end_line": 44, "start_col": 0, "start_line": 38 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
m: Prims.nat{m <= n} -> i: Prims.nat{i < n} -> FStar.Pervasives.Lemma (ensures Prims.pow2 m <= Prims.pow2 n /\ (i < n - m ==> FStar.UInt.nth (Prims.pow2 m - 1) i == false) /\ (n - m <= i ==> FStar.UInt.nth (Prims.pow2 m - 1) i == true))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "Prims.op_Equality", "Prims.int", "FStar.UInt.one_to_vec_lemma", "Prims.bool", "Prims.l_or", "Prims.l_and", "Prims.op_GreaterThanOrEqual", "Prims.op_GreaterThan", "FStar.UInt.ones_to_vec_lemma", "Prim...
[ "recursion" ]
false
false
true
false
false
let rec nth_pow2_minus_one' #n m i =
let a = pow2 m - 1 in M.pow2_le_compat n m; if m = 0 then U.one_to_vec_lemma #n i else if m = n then U.ones_to_vec_lemma #n i else if i = n - 1 then () else nth_pow2_minus_one' #(n - 1) (m - 1) i
false
LowParse.BitFields.fst
LowParse.BitFields.nth_get_bitfield
val nth_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield x lo hi) i == (i < hi - lo && nth x (i + lo)))
val nth_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield x lo hi) i == (i < hi - lo && nth x (i + lo)))
let nth_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) (i: nat {i < tot}) : Lemma (nth (get_bitfield x lo hi) i == (i < hi - lo && nth x (i + lo))) = nth_get_bitfield_raw x lo hi i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 32, "end_line": 210, "start_col": 0, "start_line": 208 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth (LowParse.BitFields.get_bitfield x lo hi) i == (i < hi - lo && LowParse.BitFields.nth x (i + lo)))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "LowParse.BitFields.nth_get_bitfield_raw", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.bool", "LowParse.BitFields.nth", "LowParse.BitFields.ge...
[]
true
false
true
false
false
let nth_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield x lo hi) i == (i < hi - lo && nth x (i + lo))) =
nth_get_bitfield_raw x lo hi i
false
LowParse.BitFields.fst
LowParse.BitFields.nth_le_pow2_m
val nth_le_pow2_m (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires (a < pow2 m /\ m <= i)) (ensures (nth a i == false))
val nth_le_pow2_m (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires (a < pow2 m /\ m <= i)) (ensures (nth a i == false))
let nth_le_pow2_m (#n: pos) (a: U.uint_t n) (m: nat {m <= n}) (i: nat {i < n}) : Lemma (requires (a < pow2 m /\ m <= i)) (ensures (nth a i == false)) = logand_mask a m; M.modulo_lemma a (pow2 m); nth_pow2_minus_one #n m i; nth_logand a (pow2 m - 1) i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 29, "end_line": 192, "start_col": 0, "start_line": 181 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t n -> m: Prims.nat{m <= n} -> i: Prims.nat{i < n} -> FStar.Pervasives.Lemma (requires a < Prims.pow2 m /\ m <= i) (ensures LowParse.BitFields.nth a i == false)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "LowParse.BitFields.nth_logand", "Prims.op_Subtraction", "Prims.pow2", "Prims.unit", "LowParse.BitFields.nth_pow2_minus_one", "FStar.Math.Lemmas.modulo_lemma", "LowParse.BitFields.log...
[]
true
false
true
false
false
let nth_le_pow2_m (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) (i: nat{i < n}) : Lemma (requires (a < pow2 m /\ m <= i)) (ensures (nth a i == false)) =
logand_mask a m; M.modulo_lemma a (pow2 m); nth_pow2_minus_one #n m i; nth_logand a (pow2 m - 1) i
false
LowParse.BitFields.fst
LowParse.BitFields.nth_get_bitfield_raw
val nth_get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield_raw x lo hi) i == (i < hi - lo && nth x (i + lo)))
val nth_get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield_raw x lo hi) i == (i < hi - lo && nth x (i + lo)))
let nth_get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) (i: nat {i < tot}) : Lemma (nth (get_bitfield_raw x lo hi) i == (i < hi - lo && nth x (i + lo))) = nth_shift_right (x `U.logand` bitfield_mask tot lo hi) lo i; if i + lo < tot then begin nth_logand x (bitfield_m...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 6, "end_line": 143, "start_col": 0, "start_line": 135 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth (LowParse.BitFields.get_bitfield_raw x lo hi) i == (i < hi - lo && LowParse.BitFields.nth x (i + lo)))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "Prims.op_Addition", "LowParse.BitFields.nth_bitfield_mask", "Prims.unit", "LowParse.BitFields.nth_logand", "LowParse.BitFields.bitfield_mask", "Prims.bool", "LowPars...
[]
false
false
true
false
false
let nth_get_bitfield_raw (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (get_bitfield_raw x lo hi) i == (i < hi - lo && nth x (i + lo))) =
nth_shift_right (x `U.logand` (bitfield_mask tot lo hi)) lo i; if i + lo < tot then (nth_logand x (bitfield_mask tot lo hi) (i + lo); nth_bitfield_mask tot lo hi (i + lo))
false
LowParse.BitFields.fst
LowParse.BitFields.nth_not_bitfield_mask
val nth_not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (not_bitfield_mask tot lo hi) i == (i < lo || hi <= i))
val nth_not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (not_bitfield_mask tot lo hi) i == (i < lo || hi <= i))
let nth_not_bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (i: nat {i < tot}) : Lemma (nth (not_bitfield_mask tot lo hi) i == (i < lo || hi <= i)) = nth_lognot (bitfield_mask tot lo hi) i; nth_bitfield_mask tot lo hi i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 31, "end_line": 295, "start_col": 0, "start_line": 292 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth (LowParse.BitFields.not_bitfield_mask tot lo hi) i == (i < lo || hi <= i))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "LowParse.BitFields.nth_bitfield_mask", "Prims.unit", "LowParse.BitFields.nth_lognot", "LowParse.BitFields.bitfield_mask", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.bool", "Lo...
[]
true
false
true
false
false
let nth_not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (i: nat{i < tot}) : Lemma (nth (not_bitfield_mask tot lo hi) i == (i < lo || hi <= i)) =
nth_lognot (bitfield_mask tot lo hi) i; nth_bitfield_mask tot lo hi i
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_raw_bounded
val get_bitfield_raw_bounded (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield_raw x lo hi < pow2 (hi - lo))
val get_bitfield_raw_bounded (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield_raw x lo hi < pow2 (hi - lo))
let get_bitfield_raw_bounded (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield_raw x lo hi < pow2 (hi - lo)) = get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one x lo hi; logand_mask (get_bitfield_raw x lo hi) (hi - lo); M.lemma_mod_lt x (pow2 (hi - lo))
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 35, "end_line": 200, "start_col": 0, "start_line": 194 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield_raw x lo hi < Prims.pow2 (hi - lo))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Math.Lemmas.lemma_mod_lt", "Prims.pow2", "Prims.op_Subtraction", "Prims.unit", "LowParse.BitFields.logand_mask", "LowParse.BitFields.get_bitfield_raw", "LowParse.BitFields.get_bitfie...
[]
true
false
true
false
false
let get_bitfield_raw_bounded (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield_raw x lo hi < pow2 (hi - lo)) =
get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one x lo hi; logand_mask (get_bitfield_raw x lo hi) (hi - lo); M.lemma_mod_lt x (pow2 (hi - lo))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask_mod_pow2_lo
val bitfield_mask_mod_pow2_lo (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (m: nat{m <= lo}) : Lemma (bitfield_mask tot lo hi % pow2 m == 0)
val bitfield_mask_mod_pow2_lo (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (m: nat{m <= lo}) : Lemma (bitfield_mask tot lo hi % pow2 m == 0)
let bitfield_mask_mod_pow2_lo (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (m: nat {m <= lo}) : Lemma (bitfield_mask tot lo hi % pow2 m == 0) = M.pow2_multiplication_modulo_lemma_1 (pow2 (hi - lo) - 1) m lo
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 64, "end_line": 262, "start_col": 0, "start_line": 258 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> m: Prims.nat{m <= lo} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.bitfield_mask tot lo hi % Prims.pow2 m == 0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Math.Lemmas.pow2_multiplication_modulo_lemma_1", "Prims.op_Subtraction", "Prims.pow2", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.int", "Prims.op_Modulus", "LowParse.BitFields....
[]
true
false
true
false
false
let bitfield_mask_mod_pow2_lo (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (m: nat{m <= lo}) : Lemma (bitfield_mask tot lo hi % pow2 m == 0) =
M.pow2_multiplication_modulo_lemma_1 (pow2 (hi - lo) - 1) m lo
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield
val set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Tot (U.uint_t tot)
val set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Tot (U.uint_t tot)
let set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Tot (U.uint_t tot) = (x `U.logand` not_bitfield_mask tot lo hi) `U.logor` (v `U.shift_left` lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 76, "end_line": 301, "start_col": 0, "start_line": 297 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> FStar.UInt.uint_t tot
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "FStar.UInt.logor", "FStar.UInt.logand", "LowParse.BitFields.not_bitfield_mask", "FStar.UInt.shift_left" ]
[]
false
false
false
false
false
let set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) : Tot (U.uint_t tot) =
(x `U.logand` (not_bitfield_mask tot lo hi)) `U.logor` (v `U.shift_left` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield
val get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Tot (ubitfield tot (hi - lo))
val get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Tot (ubitfield tot (hi - lo))
let get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Tot (ubitfield tot (hi - lo)) = get_bitfield_raw_bounded x lo hi; get_bitfield_raw x lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 26, "end_line": 206, "start_col": 0, "start_line": 202 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> LowParse.BitFields.ubitfield tot (hi - lo)
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.get_bitfield_raw", "Prims.unit", "LowParse.BitFields.get_bitfield_raw_bounded", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction" ]
[]
false
false
false
false
false
let get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (ubitfield tot (hi - lo)) =
get_bitfield_raw_bounded x lo hi; get_bitfield_raw x lo hi
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one
val get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (let y = get_bitfield_raw x lo hi in pow2 (hi - lo) - 1 < pow2 tot /\ y == y `U.logand` (pow2 (hi - lo) - 1))
val get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (let y = get_bitfield_raw x lo hi in pow2 (hi - lo) - 1 < pow2 tot /\ y == y `U.logand` (pow2 (hi - lo) - 1))
let get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (let y = get_bitfield_raw x lo hi in pow2 (hi - lo) - 1 < pow2 tot /\ y == y `U.logand` (pow2 (hi - lo) - 1) ) = nth_pow2_minus_one #tot (hi - lo) 0; let y = get_bitfield_r...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 156, "start_col": 0, "start_line": 145 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures (let y = LowParse.BitFields.get_bitfield_raw x lo hi in Prims.pow2 (hi - lo) - 1 < Prims.pow2 tot /\ y == FStar.UInt.logand y (Prims.pow2 (hi - lo) - 1)))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "FStar.UInt.logand", "Prims.op_Subtraction", "Prims.pow2", "Prims.op_LessThan", "LowParse.BitFields.nth_logand", "Prims.unit", "LowParse.BitFields.nth_pow2_mi...
[]
false
false
true
false
false
let get_bitfield_raw_eq_logand_pow2_hi_lo_minus_one (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (let y = get_bitfield_raw x lo hi in pow2 (hi - lo) - 1 < pow2 tot /\ y == y `U.logand` (pow2 (hi - lo) - 1)) =
nth_pow2_minus_one #tot (hi - lo) 0; let y = get_bitfield_raw x lo hi in eq_nth y (y `U.logand` (pow2 (hi - lo) - 1)) (fun i -> nth_get_bitfield_raw x lo hi i; nth_pow2_minus_one #tot (hi - lo) i; nth_logand y (pow2 (hi - lo) - 1) i)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask_lt_pow2_hi
val bitfield_mask_lt_pow2_hi (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi < pow2 hi)
val bitfield_mask_lt_pow2_hi (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi < pow2 hi)
let bitfield_mask_lt_pow2_hi (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (bitfield_mask tot lo hi < pow2 hi) = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 28, "end_line": 270, "start_col": 0, "start_line": 264 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.bitfield_mask tot lo hi < Prims.pow2 hi)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Math.Lemmas.pow2_plus", "Prims.op_Subtraction", "Prims.unit", "FStar.Math.Lemmas.pow2_le_compat", "Prims.l_True", "Prims.squash", "Prims.op_LessThan", "LowParse.BitFields.bitfield_mask", "Prims.pow2", ...
[]
true
false
true
false
false
let bitfield_mask_lt_pow2_hi (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi < pow2 hi) =
M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo
false
LowParse.BitFields.fst
LowParse.BitFields.not_bitfield_mask
val not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (x: U.uint_t tot {x == U.lognot (bitfield_mask tot lo hi)})
val not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (x: U.uint_t tot {x == U.lognot (bitfield_mask tot lo hi)})
let not_bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (x: U.uint_t tot {x == U.lognot (bitfield_mask tot lo hi)}) = [@inline_let] let a = bitfield_mask tot hi tot in [@inline_let] let b = bitfield_mask tot 0 lo in [@inline_let] let _ = bitfield_mask_mod_pow2_lo tot hi tot l...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 24, "end_line": 290, "start_col": 0, "start_line": 273 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> x: FStar.UInt.uint_t tot {x == FStar.UInt.lognot (LowParse.BitFields.bitfield_mask tot lo hi)}
Prims.Tot
[ "total" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Pervasives.normalize_term", "FStar.UInt.uint_t", "Prims.eq2", "FStar.UInt.lognot", "LowParse.BitFields.bitfield_mask", "Prims.op_Addition", "Prims.unit", "LowParse.BitFields.eq_nth", "FStar.UInt.logor"...
[]
false
false
false
false
false
let not_bitfield_mask (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Tot (x: U.uint_t tot {x == U.lognot (bitfield_mask tot lo hi)}) =
[@@ inline_let ]let a = bitfield_mask tot hi tot in [@@ inline_let ]let b = bitfield_mask tot 0 lo in [@@ inline_let ]let _ = bitfield_mask_mod_pow2_lo tot hi tot lo; bitfield_mask_lt_pow2_hi tot 0 lo; logor_disjoint a b lo; eq_nth (a `U.logor` b) (U.lognot (bitfield_mask tot lo hi)) (fun i -> n...
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_logor
val get_bitfield_logor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logor` y) lo hi == get_bitfield x lo hi `U.logor` get_bitfield y lo hi)
val get_bitfield_logor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logor` y) lo hi == get_bitfield x lo hi `U.logor` get_bitfield y lo hi)
let get_bitfield_logor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logor` y) lo hi == get_bitfield x lo hi `U.logor` get_bitfield y lo hi) = eq_nth (get_bitfield (x `U.logor` y) lo hi) (get_bitfield x lo hi `U.logor` get_bitfield y lo hi) (fun i -> nth...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 220, "start_col": 0, "start_line": 212 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield (FStar.UInt.logor x y) lo hi == FStar.UInt.logor (LowParse.BitFields.get_bitfield x lo hi) (LowParse...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "FStar.UInt.logor", "Prims.op_LessThan", "LowParse.BitFields.nth_get_bitfield", "Prims.unit", "Prims.l_True", "Prims.squash...
[]
false
false
true
false
false
let get_bitfield_logor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logor` y) lo hi == (get_bitfield x lo hi) `U.logor` (get_bitfield y lo hi)) =
eq_nth (get_bitfield (x `U.logor` y) lo hi) ((get_bitfield x lo hi) `U.logor` (get_bitfield y lo hi)) (fun i -> nth_get_bitfield (x `U.logor` y) lo hi i; nth_get_bitfield x lo hi i; nth_get_bitfield y lo hi i)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_zero
val get_bitfield_zero (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield #tot 0 lo hi == 0)
val get_bitfield_zero (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield #tot 0 lo hi == 0)
let get_bitfield_zero (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield #tot 0 lo hi == 0) = eq_nth (get_bitfield #tot 0 lo hi) 0 (fun i -> nth_zero tot i; nth_get_bitfield #tot 0 lo hi i; if i < hi - lo then nth_zero tot (i + lo) )
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 422, "start_col": 0, "start_line": 412 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield 0 lo hi == 0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.op_LessThan", "Prims.op_Subtraction", "LowParse.BitFields.nth_zero", "Prims.op_Addition", "Prims.bool", "Prims.unit", "LowParse.BitFields...
[]
false
false
true
false
false
let get_bitfield_zero (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield #tot 0 lo hi == 0) =
eq_nth (get_bitfield #tot 0 lo hi) 0 (fun i -> nth_zero tot i; nth_get_bitfield #tot 0 lo hi i; if i < hi - lo then nth_zero tot (i + lo))
false
LowParse.BitFields.fst
LowParse.BitFields.nth_set_bitfield
val nth_set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (i: nat{i < tot}) : Lemma (nth (set_bitfield x lo hi v) i == (if lo <= i && i < hi then nth v (i - lo) else nth x i))
val nth_set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (i: nat{i < tot}) : Lemma (nth (set_bitfield x lo hi v) i == (if lo <= i && i < hi then nth v (i - lo) else nth x i))
let nth_set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (i: nat {i < tot}) : Lemma (nth (set_bitfield x lo hi v) i == (if lo <= i && i < hi then nth v (i - lo) else nth x i)) = let y = nth (set_bitfield x lo hi v) i in nth_logor (x `U.log...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 71, "end_line": 328, "start_col": 0, "start_line": 303 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth (LowParse.BitFields.set_bitfield x lo hi v) i == (match lo <= i && ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "Prims.op_LessThan", "Prims._assert", "Prims.eq2", "Prims.bool", "Prims.op_AmpAmp", "LowParse.BitFields.nth", "Prims.unit", "Lo...
[]
false
false
true
false
false
let nth_set_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (i: nat{i < tot}) : Lemma (nth (set_bitfield x lo hi v) i == (if lo <= i && i < hi then nth v (i - lo) else nth x i)) =
let y = nth (set_bitfield x lo hi v) i in nth_logor (x `U.logand` (not_bitfield_mask tot lo hi)) (v `U.shift_left` lo) i; assert (y == (nth (x `U.logand` (not_bitfield_mask tot lo hi)) i || nth (v `U.shift_left` lo) i)); nth_logand x (not_bitfield_mask tot lo hi) i; assert (y == ((nth x i && nth (not_bitfield_mask tot ...
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_set_bitfield_same_gen
val set_bitfield_set_bitfield_same_gen (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= lo /\ hi <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (ensures (set_bitfield (set_bitfield x lo hi v) lo' hi' v' =...
val set_bitfield_set_bitfield_same_gen (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= lo /\ hi <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (ensures (set_bitfield (set_bitfield x lo hi v) lo' hi' v' =...
let set_bitfield_set_bitfield_same_gen (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= lo /\ hi <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (ensures (set_bitfield (set_bitfield x lo hi v) lo' hi' v' =...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 373, "start_col": 0, "start_line": 362 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> lo': Prims.nat -> hi': Prims.nat{lo' <= lo /\ hi <= hi' /\ hi' <= tot} -> v': LowParse.BitFields.ubitfield tot (hi' - lo') -> FStar.Pervasives.Lemma (e...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "Prims.op_LessThan", "LowParse.BitFields.nth_set_bitfield", "Prims.un...
[]
false
false
true
false
false
let set_bitfield_set_bitfield_same_gen (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (lo': nat) (hi': nat{lo' <= lo /\ hi <= hi' /\ hi' <= tot}) (v': ubitfield tot (hi' - lo')) : Lemma (ensures (set_bitfield ...
eq_nth (set_bitfield (set_bitfield x lo hi v) lo' hi' v') (set_bitfield x lo' hi' v') (fun i -> nth_set_bitfield (set_bitfield x lo hi v) lo' hi' v' i; nth_set_bitfield x lo hi v i; nth_set_bitfield x lo' hi' v' i)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_full
val get_bitfield_full (#tot: pos) (x: U.uint_t tot) : Lemma (get_bitfield x 0 tot == x)
val get_bitfield_full (#tot: pos) (x: U.uint_t tot) : Lemma (get_bitfield x 0 tot == x)
let get_bitfield_full (#tot: pos) (x: U.uint_t tot) : Lemma (get_bitfield x 0 tot == x) = eq_nth (get_bitfield x 0 tot) x (fun i -> nth_get_bitfield x 0 tot i )
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 431, "start_col": 0, "start_line": 424 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x 0 tot == x)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.nat", "Prims.b2t", "Prims.op_LessThan", "LowParse.BitFields.nth_get_bitfield", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.Nil", "FStar.Pervasives.pattern" ]
[]
false
false
true
false
false
let get_bitfield_full (#tot: pos) (x: U.uint_t tot) : Lemma (get_bitfield x 0 tot == x) =
eq_nth (get_bitfield x 0 tot) x (fun i -> nth_get_bitfield x 0 tot i)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_logxor
val get_bitfield_logxor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logxor` y) lo hi == get_bitfield x lo hi `U.logxor` get_bitfield y lo hi)
val get_bitfield_logxor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logxor` y) lo hi == get_bitfield x lo hi `U.logxor` get_bitfield y lo hi)
let get_bitfield_logxor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logxor` y) lo hi == get_bitfield x lo hi `U.logxor` get_bitfield y lo hi) = eq_nth (get_bitfield (x `U.logxor` y) lo hi) (get_bitfield x lo hi `U.logxor` get_bitfield y lo hi) (fun i -> ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 230, "start_col": 0, "start_line": 222 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield (FStar.UInt.logxor x y) lo hi == FStar.UInt.logxor (LowParse.BitFields.get_bitfield x lo hi) (LowPar...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "FStar.UInt.logxor", "Prims.op_LessThan", "LowParse.BitFields.nth_get_bitfield", "Prims.unit", "Prims.l_True", "Prims.squas...
[]
false
false
true
false
false
let get_bitfield_logxor (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield (x `U.logxor` y) lo hi == (get_bitfield x lo hi) `U.logxor` (get_bitfield y lo hi) ) =
eq_nth (get_bitfield (x `U.logxor` y) lo hi) ((get_bitfield x lo hi) `U.logxor` (get_bitfield y lo hi)) (fun i -> nth_get_bitfield (x `U.logxor` y) lo hi i; nth_get_bitfield x lo hi i; nth_get_bitfield y lo hi i)
false
LowParse.BitFields.fst
LowParse.BitFields.logor_disjoint
val logor_disjoint (#n: pos) (a b: U.uint_t n) (m: nat{m <= n}) : Lemma (requires (a % pow2 m == 0 /\ b < pow2 m)) (ensures (U.logor #n a b == a + b))
val logor_disjoint (#n: pos) (a b: U.uint_t n) (m: nat{m <= n}) : Lemma (requires (a % pow2 m == 0 /\ b < pow2 m)) (ensures (U.logor #n a b == a + b))
let logor_disjoint (#n: pos) (a: U.uint_t n) (b: U.uint_t n) (m: nat {m <= n}) : Lemma (requires ( a % pow2 m == 0 /\ b < pow2 m )) (ensures (U.logor #n a b == a + b)) = if m = 0 then U.logor_lemma_1 a else if m = n then begin M.modulo_lemma a (pow2 n); U.logor_commutative a b; ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 26, "end_line": 254, "start_col": 0, "start_line": 234 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t n -> b: FStar.UInt.uint_t n -> m: Prims.nat{m <= n} -> FStar.Pervasives.Lemma (requires a % Prims.pow2 m == 0 /\ b < Prims.pow2 m) (ensures FStar.UInt.logor a b == a + b)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "Prims.int", "FStar.UInt.logor_lemma_1", "Prims.bool", "Prims.l_or", "Prims.op_GreaterThan", "Prims.l_and", "Prims.op_GreaterThanOrEqual", "Prims.unit", "FStar.UInt.logor_commutat...
[]
false
false
true
false
false
let logor_disjoint (#n: pos) (a b: U.uint_t n) (m: nat{m <= n}) : Lemma (requires (a % pow2 m == 0 /\ b < pow2 m)) (ensures (U.logor #n a b == a + b)) =
if m = 0 then U.logor_lemma_1 a else if m = n then (M.modulo_lemma a (pow2 n); U.logor_commutative a b; U.logor_lemma_1 b) else U.logor_disjoint a b m
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_set_bitfield_other
val get_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (get_bitfield (set_bitfield x lo hi v) lo' hi' == get_bitfield ...
val get_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (get_bitfield (set_bitfield x lo hi v) lo' hi' == get_bitfield ...
let get_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (get_bitfield (set_bitfield x lo hi v) lo' hi' == get_bitfield ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 360, "start_col": 0, "start_line": 346 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> lo': Prims.nat -> hi': Prims.nat{lo' <= hi' /\ hi' <= tot} -> FStar.Pervasives.Lemma (requires hi' <= lo \/ hi <= lo') (ensures LowParse.BitField...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "LowParse.BitFields.set_bitfield", "Prims.op_LessThan", "LowParse.Bit...
[]
false
false
true
false
false
let get_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (lo': nat) (hi': nat{lo' <= hi' /\ hi' <= tot}) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (get_bitfield (set_bitfield x...
eq_nth (get_bitfield (set_bitfield x lo hi v) lo' hi') (get_bitfield x lo' hi') (fun i -> nth_get_bitfield (set_bitfield x lo hi v) lo' hi' i; nth_get_bitfield x lo' hi' i; if i < hi' - lo' then nth_set_bitfield x lo hi v (i + lo'))
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_empty
val set_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) (y: ubitfield tot 0) : Lemma (set_bitfield x i i y == x)
val set_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) (y: ubitfield tot 0) : Lemma (set_bitfield x i i y == x)
let set_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) (y: ubitfield tot 0) : Lemma (set_bitfield x i i y == x) = eq_nth (set_bitfield x i i y) x (fun j -> nth_set_bitfield x i i y j )
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 403, "start_col": 0, "start_line": 397 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> i: Prims.nat{i <= tot} -> y: LowParse.BitFields.ubitfield tot 0 -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.set_bitfield x i i y == x)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "Prims.op_LessThan", "LowParse.BitFields.nth_set_bitfield", "Prims.unit", "Prims.l_True", "Prims.squash", ...
[]
false
false
true
false
false
let set_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat{i <= tot}) (y: ubitfield tot 0) : Lemma (set_bitfield x i i y == x) =
eq_nth (set_bitfield x i i y) x (fun j -> nth_set_bitfield x i i y j)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_set_bitfield_other
val set_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (set_bitfield (set_bitfield x ...
val set_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (set_bitfield (set_bitfield x ...
let set_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= tot }) (v' : ubitfield tot (hi' - lo')) : Lemma (requires (hi' <= lo \/ hi <= lo')) (ensures (set_bitfield (set_bitfield x ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 387, "start_col": 0, "start_line": 375 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> lo': Prims.nat -> hi': Prims.nat{lo' <= hi' /\ hi' <= tot} -> v': LowParse.BitFields.ubitfield tot (hi' - lo') -> FStar.Pervasives.Lemma (requires hi' <= l...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "Prims.op_LessThan", "LowParse.BitFields.nth_set_bitfield", "Prims.un...
[]
false
false
true
false
false
let set_bitfield_set_bitfield_other (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) (lo': nat) (hi': nat{lo' <= hi' /\ hi' <= tot}) (v': ubitfield tot (hi' - lo')) : Lemma (requires (hi' <= lo \/ hi <= lo')) ...
eq_nth (set_bitfield (set_bitfield x lo hi v) lo' hi' v') (set_bitfield (set_bitfield x lo' hi' v') lo hi v) (fun i -> nth_set_bitfield (set_bitfield x lo hi v) lo' hi' v' i; nth_set_bitfield x lo hi v i; nth_set_bitfield (set_bitfield x lo' hi' v') lo hi v i; nth_set_bitfield x lo' hi' v' i...
false
LowParse.BitFields.fst
LowParse.BitFields.logand_mask
val logand_mask (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) : Lemma (pow2 m <= pow2 n /\ U.logand a (pow2 m - 1) == a % pow2 m)
val logand_mask (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) : Lemma (pow2 m <= pow2 n /\ U.logand a (pow2 m - 1) == a % pow2 m)
let logand_mask (#n: pos) (a: U.uint_t n) (m: nat {m <= n}) : Lemma (pow2 m <= pow2 n /\ U.logand a (pow2 m - 1) == a % pow2 m) = M.pow2_le_compat n m; if m = 0 then begin U.logand_lemma_1 a end else if m = n then begin U.logand_lemma_2 a; M.modulo_lemma a (pow2 m) end else begin U....
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 177, "start_col": 0, "start_line": 160 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t n -> m: Prims.nat{m <= n} -> FStar.Pervasives.Lemma (ensures Prims.pow2 m <= Prims.pow2 n /\ FStar.UInt.logand a (Prims.pow2 m - 1) == a % Prims.pow2 m)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "Prims.int", "FStar.UInt.logand_lemma_1", "Prims.bool", "Prims.l_or", "Prims.op_GreaterThan", "Prims.l_and", "Prims.op_GreaterThanOrEqual", "FStar.Math.Lemmas.modulo_lemma", "Prim...
[]
false
false
true
false
false
let logand_mask (#n: pos) (a: U.uint_t n) (m: nat{m <= n}) : Lemma (pow2 m <= pow2 n /\ U.logand a (pow2 m - 1) == a % pow2 m) =
M.pow2_le_compat n m; if m = 0 then U.logand_lemma_1 a else if m = n then (U.logand_lemma_2 a; M.modulo_lemma a (pow2 m)) else U.logand_mask a m
false
LowParse.BitFields.fst
LowParse.BitFields.nth_zero
val nth_zero (tot: pos) (i: nat{i < tot}) : Lemma (nth #tot 0 i == false)
val nth_zero (tot: pos) (i: nat{i < tot}) : Lemma (nth #tot 0 i == false)
let nth_zero (tot: pos) (i: nat {i < tot}) : Lemma (nth #tot 0 i == false) = U.zero_nth_lemma #tot i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 25, "end_line": 410, "start_col": 0, "start_line": 405 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> i: Prims.nat{i < tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.nth 0 i == false)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt.zero_nth_lemma", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.bool", "LowParse.BitFields.nth", "Prims.Nil", "FStar.Pervasives.pattern" ]
[]
true
false
true
false
false
let nth_zero (tot: pos) (i: nat{i < tot}) : Lemma (nth #tot 0 i == false) =
U.zero_nth_lemma #tot i
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_full
val set_bitfield_full (#tot: pos) (x: U.uint_t tot) (y: ubitfield tot tot) : Lemma (set_bitfield x 0 tot y == y)
val set_bitfield_full (#tot: pos) (x: U.uint_t tot) (y: ubitfield tot tot) : Lemma (set_bitfield x 0 tot y == y)
let set_bitfield_full (#tot: pos) (x: U.uint_t tot) (y: ubitfield tot tot) : Lemma (set_bitfield x 0 tot y == y) = eq_nth (set_bitfield x 0 tot y) y (fun i -> nth_set_bitfield x 0 tot y i )
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 395, "start_col": 0, "start_line": 389 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> y: LowParse.BitFields.ubitfield tot tot -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.set_bitfield x 0 tot y == y)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "LowParse.BitFields.ubitfield", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "Prims.nat", "Prims.b2t", "Prims.op_LessThan", "LowParse.BitFields.nth_set_bitfield", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "Prims.Nil", ...
[]
false
false
true
false
false
let set_bitfield_full (#tot: pos) (x: U.uint_t tot) (y: ubitfield tot tot) : Lemma (set_bitfield x 0 tot y == y) =
eq_nth (set_bitfield x 0 tot y) y (fun i -> nth_set_bitfield x 0 tot y i)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_empty
val get_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) : Lemma (get_bitfield x i i == 0)
val get_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) : Lemma (get_bitfield x i i == 0)
let get_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat { i <= tot }) : Lemma (get_bitfield x i i == 0) = eq_nth (get_bitfield x i i) 0 (fun j -> nth_get_bitfield x i i j; nth_zero tot j )
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 442, "start_col": 0, "start_line": 433 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> i: Prims.nat{i <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x i i == 0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.op_LessThan", "LowParse.BitFields.nth_zero", "Prims.unit", "LowParse.BitFields.nth_get_bitfield", "Prims.l_True", "Prims.squash", "...
[]
false
false
true
false
false
let get_bitfield_empty (#tot: pos) (x: U.uint_t tot) (i: nat{i <= tot}) : Lemma (get_bitfield x i i == 0) =
eq_nth (get_bitfield x i i) 0 (fun j -> nth_get_bitfield x i i j; nth_zero tot j)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_partition
val get_bitfield_partition (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi))
val get_bitfield_partition (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi))
let get_bitfield_partition = get_bitfield_partition'
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 52, "end_line": 696, "start_col": 0, "start_line": 696 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> l: Prims.list Prims.nat -> FStar.Pervasives.Lemma (requires LowParse.BitFields.get_bitfield_partition_prop x y lo hi l) (ensures LowParse.BitFields.get_bitfield x lo hi == LowPar...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "LowParse.BitFields.get_bitfield_partition'" ]
[]
true
false
true
false
false
let get_bitfield_partition =
get_bitfield_partition'
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_partition_2
val get_bitfield_partition_2 (#tot: pos) (mid: nat { mid <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x 0 mid == get_bitfield y 0 mid /\ get_bitfield x mid tot == get_bitfield y mid tot )) (ensures ( x == y ))
val get_bitfield_partition_2 (#tot: pos) (mid: nat { mid <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x 0 mid == get_bitfield y 0 mid /\ get_bitfield x mid tot == get_bitfield y mid tot )) (ensures ( x == y ))
let get_bitfield_partition_2 (#tot: pos) (mid: nat { mid <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x 0 mid == get_bitfield y 0 mid /\ get_bitfield x mid tot == get_bitfield y mid tot )) (ensures ( x == y )) = get_bitfield_partition_2_gen 0 mid tot x y; get_bitfield_ful...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 21, "end_line": 678, "start_col": 0, "start_line": 664 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
mid: Prims.nat{mid <= tot} -> x: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> FStar.Pervasives.Lemma (requires LowParse.BitFields.get_bitfield x 0 mid == LowParse.BitFields.get_bitfield y 0 mid /\ LowParse.BitFields.get_bitfield x mid tot == LowParse.BitFields.get_bitfield y mid tot) ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt.uint_t", "LowParse.BitFields.get_bitfield_full", "Prims.unit", "LowParse.BitFields.get_bitfield_partition_2_gen", "Prims.l_and", "Prims.eq2", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFi...
[]
true
false
true
false
false
let get_bitfield_partition_2 (#tot: pos) (mid: nat{mid <= tot}) (x y: U.uint_t tot) : Lemma (requires (get_bitfield x 0 mid == get_bitfield y 0 mid /\ get_bitfield x mid tot == get_bitfield y mid tot)) (ensures (x == y)) =
get_bitfield_partition_2_gen 0 mid tot x y; get_bitfield_full x; get_bitfield_full y
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_partition'
val get_bitfield_partition' (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi)) (decreases l)
val get_bitfield_partition' (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi)) (decreases l)
let rec get_bitfield_partition' (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi)) (decreases l) = match l with | [] -> () | mi :: q -> g...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 45, "end_line": 694, "start_col": 0, "start_line": 680 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> l: Prims.list Prims.nat -> FStar.Pervasives.Lemma (requires LowParse.BitFields.get_bitfield_partition_prop x y lo hi l) (ensures LowParse.BitFields.get_bitfield x lo hi == LowPar...
FStar.Pervasives.Lemma
[ "lemma", "" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.list", "LowParse.BitFields.get_bitfield_partition_2_gen", "Prims.unit", "LowParse.BitFields.get_bitfield_partition'", "LowParse.BitFields.get_bitfield_partition_prop", "Prims.squash", ...
[ "recursion" ]
false
false
true
false
false
let rec get_bitfield_partition' (#tot: pos) (x y: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (l: list nat) : Lemma (requires (get_bitfield_partition_prop x y lo hi l)) (ensures (get_bitfield x lo hi == get_bitfield y lo hi)) (decreases l) =
match l with | [] -> () | mi :: q -> get_bitfield_partition' x y mi hi q; get_bitfield_partition_2_gen lo mi hi x y
false
LowParse.BitFields.fst
LowParse.BitFields.pow2_m_minus_one_eq
val pow2_m_minus_one_eq (n m: nat) : Lemma (requires (m <= n)) (ensures ((pow2 n - 1) / pow2 m == pow2 (n - m) - 1))
val pow2_m_minus_one_eq (n m: nat) : Lemma (requires (m <= n)) (ensures ((pow2 n - 1) / pow2 m == pow2 (n - m) - 1))
let pow2_m_minus_one_eq (n: nat) (m: nat) : Lemma (requires (m <= n)) (ensures ( (pow2 n - 1) / pow2 m == pow2 (n - m) - 1 )) = M.pow2_le_compat n m; M.pow2_plus (n - m) m; M.division_definition (pow2 n - 1) (pow2 m) (pow2 (n - m) - 1)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 64, "end_line": 844, "start_col": 0, "start_line": 834 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
n: Prims.nat -> m: Prims.nat -> FStar.Pervasives.Lemma (requires m <= n) (ensures (Prims.pow2 n - 1) / Prims.pow2 m == Prims.pow2 (n - m) - 1)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "FStar.Math.Lemmas.division_definition", "Prims.op_Subtraction", "Prims.pow2", "Prims.unit", "FStar.Math.Lemmas.pow2_plus", "FStar.Math.Lemmas.pow2_le_compat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.squash", "Prims.eq2", "Prims.int", "Prims.op_Division", "Prims.Nil", ...
[]
true
false
true
false
false
let pow2_m_minus_one_eq (n m: nat) : Lemma (requires (m <= n)) (ensures ((pow2 n - 1) / pow2 m == pow2 (n - m) - 1)) =
M.pow2_le_compat n m; M.pow2_plus (n - m) m; M.division_definition (pow2 n - 1) (pow2 m) (pow2 (n - m) - 1)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq64_lhs
val bitfield_eq64_lhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot U64.t
val bitfield_eq64_lhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot U64.t
let bitfield_eq64_lhs (x: U64.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 64}) : Tot U64.t = x `U64.logand` bitfield_mask64 lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 38, "end_line": 927, "start_col": 0, "start_line": 924 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> FStar.UInt64.t
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt64.logand", "LowParse.BitFields.bitfield_mask64" ]
[]
false
false
false
false
false
let bitfield_eq64_lhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot U64.t =
x `U64.logand` (bitfield_mask64 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.nth_size
val nth_size (n1: nat) (n2: nat{n1 <= n2}) (x: U.uint_t n1) (i: nat{i < n2}) : Lemma (x < pow2 n2 /\ nth #n2 x i == (i < n1 && nth #n1 x i))
val nth_size (n1: nat) (n2: nat{n1 <= n2}) (x: U.uint_t n1) (i: nat{i < n2}) : Lemma (x < pow2 n2 /\ nth #n2 x i == (i < n1 && nth #n1 x i))
let rec nth_size (n1: nat) (n2: nat { n1 <= n2 }) (x: U.uint_t n1) (i: nat { i < n2 }) : Lemma (x < pow2 n2 /\ nth #n2 x i == (i < n1 && nth #n1 x i)) = M.pow2_le_compat n2 n1; if i < n1 then begin if i = 0 then () else nth_size (n1 - 1) (n2 - 1) (x / 2) (i - 1) end else nth_le_pow2_m #n2 x n1 i
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 35, "end_line": 706, "start_col": 0, "start_line": 698 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
n1: Prims.nat -> n2: Prims.nat{n1 <= n2} -> x: FStar.UInt.uint_t n1 -> i: Prims.nat{i < n2} -> FStar.Pervasives.Lemma (ensures x < Prims.pow2 n2 /\ LowParse.BitFields.nth x i == (i < n1 && LowParse.BitFields.nth x i))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt.uint_t", "Prims.op_LessThan", "Prims.op_Equality", "Prims.int", "Prims.bool", "LowParse.BitFields.nth_size", "Prims.op_Subtraction", "Prims.op_Division", "Prims.unit", "LowParse.BitFields.nth_le_pow2_m", "FStar.Math.Lemmas.p...
[ "recursion" ]
false
false
true
false
false
let rec nth_size (n1: nat) (n2: nat{n1 <= n2}) (x: U.uint_t n1) (i: nat{i < n2}) : Lemma (x < pow2 n2 /\ nth #n2 x i == (i < n1 && nth #n1 x i)) =
M.pow2_le_compat n2 n1; if i < n1 then if i = 0 then () else nth_size (n1 - 1) (n2 - 1) (x / 2) (i - 1) else nth_le_pow2_m #n2 x n1 i
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_size
val get_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) : Lemma (x < pow2 tot2 /\ (get_bitfield #tot1 x lo hi <: nat) == (get_bitfield #tot2 x lo hi <: nat))
val get_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) : Lemma (x < pow2 tot2 /\ (get_bitfield #tot1 x lo hi <: nat) == (get_bitfield #tot2 x lo hi <: nat))
let get_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) : Lemma (x < pow2 tot2 /\ (get_bitfield #tot1 x lo hi <: nat) == (get_bitfield #tot2 x lo hi <: nat)) = M.pow2_le_compat tot2 tot1; eq_nth #tot2 (get_bitfield #tot1 x lo hi) (get_...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 730, "start_col": 0, "start_line": 708 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
tot1: Prims.pos -> tot2: Prims.pos -> x: Prims.nat{x < Prims.pow2 tot1 /\ tot1 <= tot2} -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot1} -> FStar.Pervasives.Lemma (ensures x < Prims.pow2 tot2 /\ LowParse.BitFields.get_bitfield x lo hi == LowParse.BitFields.get_bitfield x ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Prims.pow2", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.op_Subtraction", "LowParse.BitFields.nth_size", "Prims.op_Addition", "Prims.bool", "Prims.unit", "Pr...
[]
false
false
true
false
false
let get_bitfield_size (tot1 tot2: pos) (x: nat{x < pow2 tot1 /\ tot1 <= tot2}) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot1}) : Lemma (x < pow2 tot2 /\ (get_bitfield #tot1 x lo hi <: nat) == (get_bitfield #tot2 x lo hi <: nat)) =
M.pow2_le_compat tot2 tot1; eq_nth #tot2 (get_bitfield #tot1 x lo hi) (get_bitfield #tot2 x lo hi) (fun i -> let y1 = nth #tot2 (get_bitfield #tot1 x lo hi) i in let y2 = nth #tot2 (get_bitfield #tot2 x lo hi) i in nth_get_bitfield #tot2 x lo hi i; assert (y2 == (i < hi - lo && nth #tot2 x...
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq32_lhs
val bitfield_eq32_lhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot U32.t
val bitfield_eq32_lhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot U32.t
let bitfield_eq32_lhs (x: U32.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 32}) : Tot U32.t = x `U32.logand` bitfield_mask32 lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 38, "end_line": 1004, "start_col": 0, "start_line": 1001 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> FStar.UInt32.t
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.logand", "LowParse.BitFields.bitfield_mask32" ]
[]
false
false
false
false
false
let bitfield_eq32_lhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot U32.t =
x `U32.logand` (bitfield_mask32 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_size
val set_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) (v: ubitfield tot1 (hi - lo)) : Lemma (x < pow2 tot2 /\ v < pow2 tot2 /\ (set_bitfield #tot1 x lo hi v <: nat) == (set_bitfield #tot2 x lo hi v <: nat))
val set_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) (v: ubitfield tot1 (hi - lo)) : Lemma (x < pow2 tot2 /\ v < pow2 tot2 /\ (set_bitfield #tot1 x lo hi v <: nat) == (set_bitfield #tot2 x lo hi v <: nat))
let set_bitfield_size (tot1 tot2: pos) (x: nat { x < pow2 tot1 /\ tot1 <= tot2 }) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot1 }) (v: ubitfield tot1 (hi - lo)) : Lemma (x < pow2 tot2 /\ v < pow2 tot2 /\ (set_bitfield #tot1 x lo hi v <: nat) == (set_bitfield #tot2 x lo hi v <: nat)) = M.pow2_le_compat tot2 t...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 753, "start_col": 0, "start_line": 732 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
tot1: Prims.pos -> tot2: Prims.pos -> x: Prims.nat{x < Prims.pow2 tot1 /\ tot1 <= tot2} -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot1} -> v: LowParse.BitFields.ubitfield tot1 (hi - lo) -> FStar.Pervasives.Lemma (ensures x < Prims.pow2 tot2 /\ v < Prims.pow2 tot2 /\ ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Prims.pow2", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "Prims.op_AmpAmp", "LowParse.BitFields.nth_size", "Pr...
[]
false
false
true
false
false
let set_bitfield_size (tot1 tot2: pos) (x: nat{x < pow2 tot1 /\ tot1 <= tot2}) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot1}) (v: ubitfield tot1 (hi - lo)) : Lemma (x < pow2 tot2 /\ v < pow2 tot2 /\ (set_bitfield #tot1 x lo hi v <: nat) == (set_bitfield #tot2 x lo hi v <: nat)) ...
M.pow2_le_compat tot2 tot1; eq_nth #tot2 (set_bitfield #tot1 x lo hi v) (set_bitfield #tot2 x lo hi v) (fun i -> let y1 = nth #tot2 (set_bitfield #tot1 x lo hi v) i in let y2 = nth #tot2 (set_bitfield #tot2 x lo hi v) i in nth_set_bitfield #tot2 x lo hi v i; nth_size tot1 tot2 (set_bitfiel...
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_eq
val get_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == (x / pow2 lo) % pow2 (hi - lo))
val get_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == (x / pow2 lo) % pow2 (hi - lo))
let get_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat {lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == (x / pow2 lo) % pow2 (hi - lo)) = if hi - lo = 0 then begin assert (hi == lo); assert_norm (pow2 0 == 1); mod_1 (x / pow2 lo); get_bitfield_empty #tot x lo end else if hi...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 832, "start_col": 0, "start_line": 809 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x lo hi == x / Prims.pow2 lo % Prims.pow2 (hi - lo))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "Prims.int", "Prims.op_Subtraction", "LowParse.BitFields.get_bitfield_empty", "Prims.unit", "LowParse.BitFields.mod_1", "Prims.op_Division", "Prims.pow2", "FStar.Pe...
[]
false
false
true
false
false
let get_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == (x / pow2 lo) % pow2 (hi - lo)) =
if hi - lo = 0 then (assert (hi == lo); assert_norm (pow2 0 == 1); mod_1 (x / pow2 lo); get_bitfield_empty #tot x lo) else if hi - lo = tot then (assert (hi == tot); assert (lo == 0); assert_norm (pow2 0 == 1); div_1 x; M.small_mod x (pow2 tot); get_bitfield_full #tot...
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_eq
val set_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v == (x `U.logand` U.lognot ((U.lognot 0 `U.shift_right` (tot - (hi - lo))) `U.shift_left` lo)) `U.logor` (v `U.shift_left` lo))
val set_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v == (x `U.logand` U.lognot ((U.lognot 0 `U.shift_right` (tot - (hi - lo))) `U.shift_left` lo)) `U.logor` (v `U.shift_left` lo))
let set_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v == (x `U.logand` U.lognot ((U.lognot 0 `U.shift_right` (tot - (hi - lo))) `U.shift_left` lo)) `U.logor` (v `U.shift_left` lo)) = bitfield_mask_eq_2 tot lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 30, "end_line": 872, "start_col": 0, "start_line": 868 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.set_bitfield x lo hi v == FStar.UInt.logor (FStar.UInt.logand x (FStar.UInt.lognot (FSta...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "LowParse.BitFields.bitfield_mask_eq_2", "Prims.unit", "Prims.l_True", "Prims.squash", "Prims.eq2", "LowParse.BitFields.set_bitfiel...
[]
true
false
true
false
false
let set_bitfield_eq (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v == (x `U.logand` (U.lognot (((U.lognot 0) `U.shift_right` (tot - (hi - lo))) `U.shift_left` lo))) `U.logor` (v...
bitfield_mask_eq_2 tot lo hi
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_bound
val set_bitfield_bound (#tot: pos) (x: U.uint_t tot) (bound: nat { bound <= tot /\ x < pow2 bound }) (lo: nat) (hi: nat { lo <= hi /\ hi <= bound }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v < pow2 bound)
val set_bitfield_bound (#tot: pos) (x: U.uint_t tot) (bound: nat { bound <= tot /\ x < pow2 bound }) (lo: nat) (hi: nat { lo <= hi /\ hi <= bound }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v < pow2 bound)
let set_bitfield_bound (#tot: pos) (x: U.uint_t tot) (bound: nat { bound <= tot /\ x < pow2 bound }) (lo: nat) (hi: nat { lo <= hi /\ hi <= bound }) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v < pow2 bound) = if bound = 0 then set_bitfield_empty x lo v else begin M.pow2_le_compat ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 770, "start_col": 0, "start_line": 755 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> bound: Prims.nat{bound <= tot /\ x < Prims.pow2 bound} -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= bound} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.set_bitfield x lo hi v < Prims.pow2 bound)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "Prims.pow2", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "Prims.op_Equality", "Prims.int", "LowParse.BitFields.set_bitfield_empty", "Prims.bool", "LowP...
[]
false
false
true
false
false
let set_bitfield_bound (#tot: pos) (x: U.uint_t tot) (bound: nat{bound <= tot /\ x < pow2 bound}) (lo: nat) (hi: nat{lo <= hi /\ hi <= bound}) (v: ubitfield tot (hi - lo)) : Lemma (set_bitfield x lo hi v < pow2 bound) =
if bound = 0 then set_bitfield_empty x lo v else (M.pow2_le_compat tot bound; M.pow2_le_compat bound (hi - lo); set_bitfield_size bound tot x lo hi v)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_get_bitfield
val set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (set_bitfield x lo hi (get_bitfield x lo hi) == x)
val set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (set_bitfield x lo hi (get_bitfield x lo hi) == x)
let set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (set_bitfield x lo hi (get_bitfield x lo hi) == x) = eq_nth (set_bitfield x lo hi (get_bitfield x lo hi)) x (fun i -> nth_set_bitfield x lo hi (get_bitfield x lo hi) i; if lo <= i && i < hi ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 625, "start_col": 0, "start_line": 615 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.set_bitfield x lo hi (LowParse.BitFields.get_bitfield x lo hi) == x)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.set_bitfield", "LowParse.BitFields.get_bitfield", "Prims.op_LessThan", "Prims.op_AmpAmp", "LowParse.BitFields.nth_get_bitfield", "Prims.op_S...
[]
false
false
true
false
false
let set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (set_bitfield x lo hi (get_bitfield x lo hi) == x) =
eq_nth (set_bitfield x lo hi (get_bitfield x lo hi)) x (fun i -> nth_set_bitfield x lo hi (get_bitfield x lo hi) i; if lo <= i && i < hi then nth_get_bitfield x lo hi (i - lo))
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_eq_2
val get_bitfield_eq_2 (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield x lo hi == (x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo))
val get_bitfield_eq_2 (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield x lo hi == (x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo))
let get_bitfield_eq_2 (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield x lo hi == (x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo)) = eq_nth (get_bitfield x lo hi) ((x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo)) (fun i -> nth_get_bitf...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 856, "start_col": 0, "start_line": 846 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x lo hi == FStar.UInt.shift_right (FStar.UInt.shift_left x (tot - hi)) (tot - hi + lo))
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "FStar.UInt.shift_right", "FStar.UInt.shift_left", "Prims.op_Subtraction", "Prims.op_Addition", "Prims.op_LessThan", "LowPa...
[]
false
false
true
false
false
let get_bitfield_eq_2 (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == (x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo)) =
eq_nth (get_bitfield x lo hi) ((x `U.shift_left` (tot - hi)) `U.shift_right` (tot - hi + lo)) (fun i -> nth_get_bitfield x lo hi i; nth_shift_right (x `U.shift_left` (tot - hi)) (tot - hi + lo) i; let j = i + (tot - hi + lo) in if j < tot then nth_shift_left x (tot - hi) j)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_is_zero
val bitfield_is_zero (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == 0 <==> x `U.logand` (bitfield_mask tot lo hi) == 0)
val bitfield_is_zero (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == 0 <==> x `U.logand` (bitfield_mask tot lo hi) == 0)
let bitfield_is_zero (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma (get_bitfield x lo hi == 0 <==> x `U.logand` bitfield_mask tot lo hi == 0) = let y = x `U.logand` bitfield_mask tot lo hi in let z = get_bitfield x lo hi in let f () : Lemma (requires (y == 0)) ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 30, "end_line": 565, "start_col": 0, "start_line": 529 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x lo hi == 0 <==> FStar.UInt.logand x (LowParse.BitFields.bitfield_mask tot lo hi) == 0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Classical.move_requires", "Prims.unit", "Prims.eq2", "Prims.int", "Prims.squash", "Prims.Nil", "FStar.Pervasives.pattern", "LowParse.BitFields.eq_nth", "Prims.op_LessThan", "Pr...
[]
false
false
true
false
false
let bitfield_is_zero (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (get_bitfield x lo hi == 0 <==> x `U.logand` (bitfield_mask tot lo hi) == 0) =
let y = x `U.logand` (bitfield_mask tot lo hi) in let z = get_bitfield x lo hi in let f () : Lemma (requires (y == 0)) (ensures (z == 0)) = eq_nth z 0 (fun i -> nth_zero tot i; nth_logand x (bitfield_mask tot lo hi) i; nth_bitfield_mask tot lo hi i; nth_get_bitfield x lo hi i; ...
false
LowParse.BitFields.fst
LowParse.BitFields.lt_pow2_get_bitfield_hi
val lt_pow2_get_bitfield_hi (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (x < pow2 mi)) (ensures (get_bitfield x mi tot == 0))
val lt_pow2_get_bitfield_hi (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (x < pow2 mi)) (ensures (get_bitfield x mi tot == 0))
let lt_pow2_get_bitfield_hi (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (x < pow2 mi)) (ensures (get_bitfield x mi tot == 0)) = if mi = 0 then get_bitfield_zero tot mi tot else if mi < tot then begin M.modulo_lemma x (pow2 mi); U.logand_mask x mi; eq_nth (get_bitfie...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 463, "start_col": 0, "start_line": 444 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> mi: Prims.nat{mi <= tot} -> FStar.Pervasives.Lemma (requires x < Prims.pow2 mi) (ensures LowParse.BitFields.get_bitfield x mi tot == 0)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "Prims.int", "LowParse.BitFields.get_bitfield_zero", "Prims.bool", "Prims.op_LessThan", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "LowParse.BitFields.nth_pow2_mi...
[]
false
false
true
false
false
let lt_pow2_get_bitfield_hi (#tot: pos) (x: U.uint_t tot) (mi: nat{mi <= tot}) : Lemma (requires (x < pow2 mi)) (ensures (get_bitfield x mi tot == 0)) =
if mi = 0 then get_bitfield_zero tot mi tot else if mi < tot then (M.modulo_lemma x (pow2 mi); U.logand_mask x mi; eq_nth (get_bitfield x mi tot) 0 (fun i -> nth_zero tot i; nth_get_bitfield x mi tot i; nth_get_bitfield (x `U.logand` (pow2 mi - 1))...
false
LowParse.BitFields.fst
LowParse.BitFields.u64_shift_right
val u64_shift_right (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_right` (U32.v amount)})
val u64_shift_right (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_right` (U32.v amount)})
let u64_shift_right (x: U64.t) (amount: U32.t { U32.v amount <= 64 }) : Tot (y: U64.t { U64.v y == U64.v x `U.shift_right` U32.v amount }) = if amount = 64ul then 0uL else x `U64.shift_right` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 59, "end_line": 897, "start_col": 0, "start_line": 893 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 64} -> y: FStar.UInt64.t {FStar.UInt64.v y == FStar.UInt.shift_right (FStar.UInt64.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt64.__uint_to_t", "Prims.bool", "FStar.UInt64.shift_right", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt64.n", "FStar.UInt64.v", "FSt...
[]
false
false
false
false
false
let u64_shift_right (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_right` (U32.v amount)}) =
if amount = 64ul then 0uL else x `U64.shift_right` amount
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_zero_inner
val get_bitfield_zero_inner (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat { lo <= lo' }) (hi': nat { lo' <= hi' /\ hi' <= hi }) : Lemma (ensures (get_bitfield x lo hi == 0 ==> get_bitfield x lo' hi' == 0))
val get_bitfield_zero_inner (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat { lo <= lo' }) (hi': nat { lo' <= hi' /\ hi' <= hi }) : Lemma (ensures (get_bitfield x lo hi == 0 ==> get_bitfield x lo' hi' == 0))
let get_bitfield_zero_inner (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat { lo <= lo' }) (hi': nat { lo' <= hi' /\ hi' <= hi }) : Lemma (ensures (get_bitfield x lo hi == 0 ==> get_bitfield x lo' hi' == 0)) = let f () : Lemma (requires (get_bitfield x lo hi == 0)) ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 30, "end_line": 525, "start_col": 0, "start_line": 504 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> lo': Prims.nat{lo <= lo'} -> hi': Prims.nat{lo' <= hi' /\ hi' <= hi} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x lo hi == 0 ==> LowParse.BitFields.get_bitfield x lo' hi' =...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.Classical.move_requires", "Prims.unit", "Prims.eq2", "Prims.int", "LowParse.BitFields.get_bitfield", "Prims.squash", "Prims.Nil", "FStar.Pervasives.pattern", "LowParse.BitFields....
[]
false
false
true
false
false
let get_bitfield_zero_inner (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (lo': nat{lo <= lo'}) (hi': nat{lo' <= hi' /\ hi' <= hi}) : Lemma (ensures (get_bitfield x lo hi == 0 ==> get_bitfield x lo' hi' == 0)) =
let f () : Lemma (requires (get_bitfield x lo hi == 0)) (ensures (get_bitfield x lo' hi' == 0)) = eq_nth (get_bitfield x lo' hi') 0 (fun i -> nth_get_bitfield x lo' hi' i; nth_zero tot i; if (i < hi' - lo') then (nth_get_bitfield x lo hi (i + lo' - lo); nt...
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_hi_lt_pow2
val get_bitfield_hi_lt_pow2 (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (get_bitfield x mi tot == 0)) (ensures (x < pow2 mi))
val get_bitfield_hi_lt_pow2 (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (get_bitfield x mi tot == 0)) (ensures (x < pow2 mi))
let get_bitfield_hi_lt_pow2 (#tot: pos) (x: U.uint_t tot) (mi: nat {mi <= tot}) : Lemma (requires (get_bitfield x mi tot == 0)) (ensures (x < pow2 mi)) = if mi = 0 then get_bitfield_full x else if mi < tot then begin M.pow2_le_compat tot mi; eq_nth x (x `U.logand` (pow2 mi - 1)) (fun i -> ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 487, "start_col": 0, "start_line": 465 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> mi: Prims.nat{mi <= tot} -> FStar.Pervasives.Lemma (requires LowParse.BitFields.get_bitfield x mi tot == 0) (ensures x < Prims.pow2 mi)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "Prims.int", "LowParse.BitFields.get_bitfield_full", "Prims.bool", "Prims.op_LessThan", "FStar.Math.Lemmas.lemma_mod_lt", "Prims.pow2", "Prims.unit", "FStar.UInt.logand_mask", "Lo...
[]
false
false
true
false
false
let get_bitfield_hi_lt_pow2 (#tot: pos) (x: U.uint_t tot) (mi: nat{mi <= tot}) : Lemma (requires (get_bitfield x mi tot == 0)) (ensures (x < pow2 mi)) =
if mi = 0 then get_bitfield_full x else if mi < tot then (M.pow2_le_compat tot mi; eq_nth x (x `U.logand` (pow2 mi - 1)) (fun i -> nth_pow2_minus_one #tot mi i; if mi <= i then (nth_get_bitfield x mi tot (i - mi); nth_zero t...
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_set_bitfield_get_bitfield
val set_bitfield_set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= hi - lo }) (v' : ubitfield tot (hi' - lo')) : Lemma ( let v = set_bitfield (get_bitfield x lo hi) lo' hi' v' in v < pow2 (hi - lo) /\ set_b...
val set_bitfield_set_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo' : nat) (hi' : nat { lo' <= hi' /\ hi' <= hi - lo }) (v' : ubitfield tot (hi' - lo')) : Lemma ( let v = set_bitfield (get_bitfield x lo hi) lo' hi' v' in v < pow2 (hi - lo) /\ set_b...
let set_bitfield_set_bitfield_get_bitfield #tot x lo hi lo' hi' v' = set_bitfield_bound (get_bitfield x lo hi) (hi - lo) lo' hi' v' ; let x1 = set_bitfield x lo hi (set_bitfield (get_bitfield x lo hi) lo' hi' v') in let x2 = set_bitfield x (lo + lo') (lo + hi') v' in eq_nth x1 x2 (fun i -> nth_set_bitfield ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 797, "start_col": 0, "start_line": 774 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
x: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> lo': Prims.nat -> hi': Prims.nat{lo' <= hi' /\ hi' <= hi - lo} -> v': LowParse.BitFields.ubitfield tot (hi' - lo') -> FStar.Pervasives.Lemma (ensures (let v = LowParse.BitFields.set_bitfie...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Subtraction", "LowParse.BitFields.ubitfield", "LowParse.BitFields.eq_nth", "Prims.op_LessThan", "Prims.op_AmpAmp", "Prims.bool", "Prims._assert", "Prims.eq2", "Prims.int", "...
[]
false
false
true
false
false
let set_bitfield_set_bitfield_get_bitfield #tot x lo hi lo' hi' v' =
set_bitfield_bound (get_bitfield x lo hi) (hi - lo) lo' hi' v'; let x1 = set_bitfield x lo hi (set_bitfield (get_bitfield x lo hi) lo' hi' v') in let x2 = set_bitfield x (lo + lo') (lo + hi') v' in eq_nth x1 x2 (fun i -> nth_set_bitfield x lo hi (set_bitfield (get_bitfield x lo hi) lo' hi' v') i; nth_se...
false
LowParse.BitFields.fst
LowParse.BitFields.not_bitfield_mask64
val not_bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == not_bitfield_mask 64 lo hi})
val not_bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == not_bitfield_mask 64 lo hi})
let not_bitfield_mask64 (lo: nat) (hi: nat { lo <= hi /\ hi <= 64 }) : Tot (x: U64.t { U64.v x == not_bitfield_mask 64 lo hi }) = U64.lognot (bitfield_mask64 lo hi)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 36, "end_line": 907, "start_col": 0, "start_line": 906 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> x: FStar.UInt64.t{FStar.UInt64.v x == LowParse.BitFields.not_bitfield_mask 64 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt64.lognot", "LowParse.BitFields.bitfield_mask64", "FStar.UInt64.t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt64.v", "LowParse.BitFields.not_bitfield_mask" ]
[]
false
false
false
false
false
let not_bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == not_bitfield_mask 64 lo hi}) =
U64.lognot (bitfield_mask64 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.not_bitfield_mask32
val not_bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == not_bitfield_mask 32 lo hi})
val not_bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == not_bitfield_mask 32 lo hi})
let not_bitfield_mask32 (lo: nat) (hi: nat { lo <= hi /\ hi <= 32 }) : Tot (x: U32.t { U32.v x == not_bitfield_mask 32 lo hi }) = U32.lognot (bitfield_mask32 lo hi)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 36, "end_line": 984, "start_col": 0, "start_line": 983 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> x: FStar.UInt32.t{FStar.UInt32.v x == LowParse.BitFields.not_bitfield_mask 32 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.lognot", "LowParse.BitFields.bitfield_mask32", "FStar.UInt32.t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt32.v", "LowParse.BitFields.not_bitfield_mask" ]
[]
false
false
false
false
false
let not_bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == not_bitfield_mask 32 lo hi}) =
U32.lognot (bitfield_mask32 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield64
val get_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) lo hi})
val get_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) lo hi})
let get_bitfield64 (x: U64.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 64}) : Tot (y: U64.t { U64.v y == get_bitfield (U64.v x) lo hi }) = (x `U64.logand` bitfield_mask64 lo hi) `u64_shift_right` (U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 77, "end_line": 903, "start_col": 0, "start_line": 900 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> y: FStar.UInt64.t{FStar.UInt64.v y == LowParse.BitFields.get_bitfield (FStar.UInt64.v x) lo hi}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.u64_shift_right", "FStar.UInt64.logand", "LowParse.BitFields.bitfield_mask64", "FStar.UInt32.uint_to_t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt64.n", "FStar.UInt64.v", "LowPars...
[]
false
false
false
false
false
let get_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) lo hi}) =
(x `U64.logand` (bitfield_mask64 lo hi)) `u64_shift_right` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_get_bitfield
val get_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat) (hi': nat { lo' <= hi' /\ hi' <= hi - lo }) : Lemma (get_bitfield (get_bitfield x lo hi) lo' hi' == get_bitfield x (lo + lo') (lo + hi'))
val get_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat) (hi': nat { lo' <= hi' /\ hi' <= hi - lo }) : Lemma (get_bitfield (get_bitfield x lo hi) lo' hi' == get_bitfield x (lo + lo') (lo + hi'))
let get_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (lo': nat) (hi': nat { lo' <= hi' /\ hi' <= hi - lo }) : Lemma (get_bitfield (get_bitfield x lo hi) lo' hi' == get_bitfield x (lo + lo') (lo + hi')) = eq_nth (get_bitfield (get_bitfield x lo hi) lo' hi') ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 501, "start_col": 0, "start_line": 489 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> lo': Prims.nat -> hi': Prims.nat{lo' <= hi' /\ hi' <= hi - lo} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield (LowParse.BitFields.get_bitfield x lo hi) lo' hi' == LowParse.BitF...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Subtraction", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.op_Addition", "Prims.op_LessThan", "LowParse.BitFields.nth_get_bitfield", "Prims.bool", "Pri...
[]
false
false
true
false
false
let get_bitfield_get_bitfield (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (lo': nat) (hi': nat{lo' <= hi' /\ hi' <= hi - lo}) : Lemma (get_bitfield (get_bitfield x lo hi) lo' hi' == get_bitfield x (lo + lo') (lo + hi')) =
eq_nth (get_bitfield (get_bitfield x lo hi) lo' hi') (get_bitfield x (lo + lo') (lo + hi')) (fun i -> nth_get_bitfield (get_bitfield x lo hi) lo' hi' i; nth_get_bitfield x (lo + lo') (lo + hi') i; if i < hi' - lo' then nth_get_bitfield x lo hi (i + lo'))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask64
val bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == bitfield_mask 64 lo hi})
val bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == bitfield_mask 64 lo hi})
let bitfield_mask64 (lo: nat) (hi: nat { lo <= hi /\ hi <= 64 }) : Tot (x: U64.t { U64.v x == bitfield_mask 64 lo hi }) = if lo = hi then 0uL else begin bitfield_mask_eq_2 64 lo hi; (U64.lognot 0uL `U64.shift_right` (64ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U64.shift_left` U32.uint_to_t lo end
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 890, "start_col": 0, "start_line": 884 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> x: FStar.UInt64.t{FStar.UInt64.v x == LowParse.BitFields.bitfield_mask 64 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "FStar.UInt64.__uint_to_t", "Prims.bool", "FStar.UInt64.shift_left", "FStar.UInt64.shift_right", "FStar.UInt64.lognot", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt32.uint_to_t", "Prims...
[]
false
false
false
false
false
let bitfield_mask64 (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) : Tot (x: U64.t{U64.v x == bitfield_mask 64 lo hi}) =
if lo = hi then 0uL else (bitfield_mask_eq_2 64 lo hi; ((U64.lognot 0uL) `U64.shift_right` (64ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U64.shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq16_lhs
val bitfield_eq16_lhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot U16.t
val bitfield_eq16_lhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot U16.t
let bitfield_eq16_lhs (x: U16.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 16}) : Tot U16.t = x `U16.logand` bitfield_mask16 lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 38, "end_line": 1081, "start_col": 0, "start_line": 1078 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> FStar.UInt16.t
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt16.logand", "LowParse.BitFields.bitfield_mask16" ]
[]
false
false
false
false
false
let bitfield_eq16_lhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot U16.t =
x `U16.logand` (bitfield_mask16 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.u64_shift_left
val u64_shift_left (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_left` (U32.v amount)})
val u64_shift_left (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_left` (U32.v amount)})
let u64_shift_left (x: U64.t) (amount: U32.t { U32.v amount <= 64 }) : Tot (y: U64.t { U64.v y == U64.v x `U.shift_left` U32.v amount }) = if amount = 64ul then 0uL else x `U64.shift_left` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 58, "end_line": 914, "start_col": 0, "start_line": 910 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 64} -> y: FStar.UInt64.t {FStar.UInt64.v y == FStar.UInt.shift_left (FStar.UInt64.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt64.__uint_to_t", "Prims.bool", "FStar.UInt64.shift_left", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt64.n", "FStar.UInt64.v", "FSta...
[]
false
false
false
false
false
let u64_shift_left (x: U64.t) (amount: U32.t{U32.v amount <= 64}) : Tot (y: U64.t{U64.v y == (U64.v x) `U.shift_left` (U32.v amount)}) =
if amount = 64ul then 0uL else x `U64.shift_left` amount
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield32
val get_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) lo hi})
val get_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) lo hi})
let get_bitfield32 (x: U32.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 32}) : Tot (y: U32.t { U32.v y == get_bitfield (U32.v x) lo hi }) = (x `U32.logand` bitfield_mask32 lo hi) `u32_shift_right` (U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 77, "end_line": 980, "start_col": 0, "start_line": 977 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> y: FStar.UInt32.t{FStar.UInt32.v y == LowParse.BitFields.get_bitfield (FStar.UInt32.v x) lo hi}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.u32_shift_right", "FStar.UInt32.logand", "LowParse.BitFields.bitfield_mask32", "FStar.UInt32.uint_to_t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt32.n", "FStar.UInt32.v", "LowPars...
[]
false
false
false
false
false
let get_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) lo hi}) =
(x `U32.logand` (bitfield_mask32 lo hi)) `u32_shift_right` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield64
val set_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) lo hi (U64.v v)})
val set_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) lo hi (U64.v v)})
let set_bitfield64 (x: U64.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 64}) (v: U64.t { U64.v v < pow2 (hi - lo) }) : Tot (y: U64.t { U64.v y == set_bitfield (U64.v x) lo hi (U64.v v) }) = (x `U64.logand` not_bitfield_mask64 lo hi) `U64.logor` (v `u64_shift_left` U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 94, "end_line": 921, "start_col": 0, "start_line": 917 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> v: FStar.UInt64.t{FStar.UInt64.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt64.t { FStar.UInt64.v y == LowParse.BitFields.set_bitfield (FStar.UInt64.v x) lo hi (FStar.UInt64.v v) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt64.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt64.logor", "FStar.UInt64.logand", "LowParse.BitFields.not_bitfield_mask64", "LowParse.BitFields.u64_shift_left", "F...
[]
false
false
false
false
false
let set_bitfield64 (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) lo hi (U64.v v)}) =
(x `U64.logand` (not_bitfield_mask64 lo hi)) `U64.logor` (v `u64_shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask32
val bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == bitfield_mask 32 lo hi})
val bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == bitfield_mask 32 lo hi})
let bitfield_mask32 (lo: nat) (hi: nat { lo <= hi /\ hi <= 32 }) : Tot (x: U32.t { U32.v x == bitfield_mask 32 lo hi }) = if lo = hi then 0ul else begin bitfield_mask_eq_2 32 lo hi; (U32.lognot 0ul `U32.shift_right` (32ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U32.shift_left` U32.uint_to_t lo end
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 967, "start_col": 0, "start_line": 961 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> x: FStar.UInt32.t{FStar.UInt32.v x == LowParse.BitFields.bitfield_mask 32 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "Prims.bool", "FStar.UInt32.shift_left", "FStar.UInt32.shift_right", "FStar.UInt32.lognot", "FStar.UInt32.sub", "FStar.UInt32.uint_to_t", "Prims.op_Subtraction", "Prims.uni...
[]
false
false
false
false
false
let bitfield_mask32 (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) : Tot (x: U32.t{U32.v x == bitfield_mask 32 lo hi}) =
if lo = hi then 0ul else (bitfield_mask_eq_2 32 lo hi; ((U32.lognot 0ul) `U32.shift_right` (32ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U32.shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask_eq_2
val bitfield_mask_eq_2 (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi == U.shift_left #tot ((U.lognot 0) `U.shift_right` (tot - (hi - lo))) lo)
val bitfield_mask_eq_2 (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi == U.shift_left #tot ((U.lognot 0) `U.shift_right` (tot - (hi - lo))) lo)
let bitfield_mask_eq_2 (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Lemma ( bitfield_mask tot lo hi == U.shift_left #tot (U.lognot 0 `U.shift_right` (tot - (hi - lo))) lo ) = bitfield_mask_eq tot lo hi; pow2_m_minus_one_eq tot (tot - (hi - lo)); U.lemma_lognot_value_mod #tot 0; U.shift_right...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 65, "end_line": 866, "start_col": 0, "start_line": 859 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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
tot: Prims.pos -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.bitfield_mask tot lo hi == FStar.UInt.shift_left (FStar.UInt.shift_right (FStar.UInt.lognot 0) (tot - (hi - lo))) lo)
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt.shift_right_value_lemma", "Prims.op_Subtraction", "Prims.pow2", "Prims.unit", "FStar.UInt.lemma_lognot_value_mod", "LowParse.BitFields.pow2_m_minus_one_eq", "LowParse.BitFields.bitfield_mask_eq", "P...
[]
true
false
true
false
false
let bitfield_mask_eq_2 (tot: pos) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) : Lemma (bitfield_mask tot lo hi == U.shift_left #tot ((U.lognot 0) `U.shift_right` (tot - (hi - lo))) lo) =
bitfield_mask_eq tot lo hi; pow2_m_minus_one_eq tot (tot - (hi - lo)); U.lemma_lognot_value_mod #tot 0; U.shift_right_value_lemma #tot (pow2 tot - 1) (tot - (hi - lo))
false
LowParse.BitFields.fst
LowParse.BitFields.u32_shift_right
val u32_shift_right (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_right` (U32.v amount)})
val u32_shift_right (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_right` (U32.v amount)})
let u32_shift_right (x: U32.t) (amount: U32.t { U32.v amount <= 32 }) : Tot (y: U32.t { U32.v y == U32.v x `U.shift_right` U32.v amount }) = if amount = 32ul then 0ul else x `U32.shift_right` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 59, "end_line": 974, "start_col": 0, "start_line": 970 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 32} -> y: FStar.UInt32.t {FStar.UInt32.v y == FStar.UInt.shift_right (FStar.UInt32.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "Prims.bool", "FStar.UInt32.shift_right", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt32.n", "FStar.UInt.shift_right" ]
[]
false
false
false
false
false
let u32_shift_right (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_right` (U32.v amount)}) =
if amount = 32ul then 0ul else x `U32.shift_right` amount
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask16
val bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == bitfield_mask 16 lo hi})
val bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == bitfield_mask 16 lo hi})
let bitfield_mask16 (lo: nat) (hi: nat { lo <= hi /\ hi <= 16 }) : Tot (x: U16.t { U16.v x == bitfield_mask 16 lo hi }) = if lo = hi then 0us else begin bitfield_mask_eq_2 16 lo hi; (U16.lognot 0us `U16.shift_right` (16ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U16.shift_left` U32.uint_to_t lo end
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 1044, "start_col": 0, "start_line": 1038 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> x: FStar.UInt16.t{FStar.UInt16.v x == LowParse.BitFields.bitfield_mask 16 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "FStar.UInt16.__uint_to_t", "Prims.bool", "FStar.UInt16.shift_left", "FStar.UInt16.shift_right", "FStar.UInt16.lognot", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt32.uint_to_t", "Prims...
[]
false
false
false
false
false
let bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == bitfield_mask 16 lo hi}) =
if lo = hi then 0us else (bitfield_mask_eq_2 16 lo hi; ((U16.lognot 0us) `U16.shift_right` (16ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U16.shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_gen64
val get_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) (U32.v lo) (U32.v hi)})
val get_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) (U32.v lo) (U32.v hi)})
let get_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 64}) : Tot (y: U64.t { U64.v y == get_bitfield (U64.v x) (U32.v lo) (U32.v hi) }) = get_bitfield_eq_2 #64 (U64.v x) (U32.v lo) (U32.v hi); (x `U64.shift_left` (64ul `U32.sub` hi)) `U64.shift_right` ((64ul `U32.sub` hi) `U32...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 95, "end_line": 948, "start_col": 0, "start_line": 944 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 64} -> y: FStar.UInt64.t { FStar.UInt64.v y == LowParse.BitFields.get_bitfield (FStar.UInt64.v x) (FStar.UInt32.v lo) (FStar.UInt32.v hi) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt64.shift_right", "FStar.UInt64.shift_left", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt32.add", "Prims.unit", "LowParse.BitFields.ge...
[]
false
false
false
false
false
let get_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) : Tot (y: U64.t{U64.v y == get_bitfield (U64.v x) (U32.v lo) (U32.v hi)}) =
get_bitfield_eq_2 #64 (U64.v x) (U32.v lo) (U32.v hi); (x `U64.shift_left` (64ul `U32.sub` hi)) `U64.shift_right` ((64ul `U32.sub` hi) `U32.add` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield32
val set_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) lo hi (U32.v v)})
val set_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) lo hi (U32.v v)})
let set_bitfield32 (x: U32.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 32}) (v: U32.t { U32.v v < pow2 (hi - lo) }) : Tot (y: U32.t { U32.v y == set_bitfield (U32.v x) lo hi (U32.v v) }) = (x `U32.logand` not_bitfield_mask32 lo hi) `U32.logor` (v `u32_shift_left` U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 94, "end_line": 998, "start_col": 0, "start_line": 994 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> v: FStar.UInt32.t{FStar.UInt32.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt32.t { FStar.UInt32.v y == LowParse.BitFields.set_bitfield (FStar.UInt32.v x) lo hi (FStar.UInt32.v v) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt32.logor", "FStar.UInt32.logand", "LowParse.BitFields.not_bitfield_mask32", "LowParse.BitFields.u32_shift_left", "F...
[]
false
false
false
false
false
let set_bitfield32 (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) lo hi (U32.v v)}) =
(x `U32.logand` (not_bitfield_mask32 lo hi)) `U32.logor` (v `u32_shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq8_lhs
val bitfield_eq8_lhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot U8.t
val bitfield_eq8_lhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot U8.t
let bitfield_eq8_lhs (x: U8.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 8}) : Tot U8.t = x `U8.logand` bitfield_mask8 lo hi
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 36, "end_line": 1190, "start_col": 0, "start_line": 1187 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 8} -> FStar.UInt8.t
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt8.logand", "LowParse.BitFields.bitfield_mask8" ]
[]
false
false
false
false
false
let bitfield_eq8_lhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot U8.t =
x `U8.logand` (bitfield_mask8 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.u16_shift_right
val u16_shift_right (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_right` (U32.v amount)})
val u16_shift_right (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_right` (U32.v amount)})
let u16_shift_right (x: U16.t) (amount: U32.t { U32.v amount <= 16 }) : Tot (y: U16.t { U16.v y == U16.v x `U.shift_right` U32.v amount }) = if amount = 16ul then 0us else x `U16.shift_right` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 59, "end_line": 1051, "start_col": 0, "start_line": 1047 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 16} -> y: FStar.UInt16.t {FStar.UInt16.v y == FStar.UInt.shift_right (FStar.UInt16.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt16.__uint_to_t", "Prims.bool", "FStar.UInt16.shift_right", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt16.n", "FStar.UInt16.v", "FSt...
[]
false
false
false
false
false
let u16_shift_right (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_right` (U32.v amount)}) =
if amount = 16ul then 0us else x `U16.shift_right` amount
false
LowParse.BitFields.fst
LowParse.BitFields.not_bitfield_mask16
val not_bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == not_bitfield_mask 16 lo hi})
val not_bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == not_bitfield_mask 16 lo hi})
let not_bitfield_mask16 (lo: nat) (hi: nat { lo <= hi /\ hi <= 16 }) : Tot (x: U16.t { U16.v x == not_bitfield_mask 16 lo hi }) = U16.lognot (bitfield_mask16 lo hi)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 36, "end_line": 1061, "start_col": 0, "start_line": 1060 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> x: FStar.UInt16.t{FStar.UInt16.v x == LowParse.BitFields.not_bitfield_mask 16 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt16.lognot", "LowParse.BitFields.bitfield_mask16", "FStar.UInt16.t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt16.v", "LowParse.BitFields.not_bitfield_mask" ]
[]
false
false
false
false
false
let not_bitfield_mask16 (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (x: U16.t{U16.v x == not_bitfield_mask 16 lo hi}) =
U16.lognot (bitfield_mask16 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_gen32
val get_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) (U32.v lo) (U32.v hi)})
val get_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) (U32.v lo) (U32.v hi)})
let get_bitfield_gen32 (x: U32.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 32}) : Tot (y: U32.t { U32.v y == get_bitfield (U32.v x) (U32.v lo) (U32.v hi) }) = get_bitfield_eq_2 #32 (U32.v x) (U32.v lo) (U32.v hi); (x `U32.shift_left` (32ul `U32.sub` hi)) `U32.shift_right` ((32ul `U32.sub` hi) `U32...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 95, "end_line": 1021, "start_col": 0, "start_line": 1017 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 32} -> y: FStar.UInt32.t { FStar.UInt32.v y == LowParse.BitFields.get_bitfield (FStar.UInt32.v x) (FStar.UInt32.v lo) (FStar.UInt32.v hi) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt32.shift_right", "FStar.UInt32.shift_left", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt32.add", "Prims.unit", "LowParse.BitFields.get_bitfield_eq_2", ...
[]
false
false
false
false
false
let get_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) : Tot (y: U32.t{U32.v y == get_bitfield (U32.v x) (U32.v lo) (U32.v hi)}) =
get_bitfield_eq_2 #32 (U32.v x) (U32.v lo) (U32.v hi); (x `U32.shift_left` (32ul `U32.sub` hi)) `U32.shift_right` ((32ul `U32.sub` hi) `U32.add` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.u16_shift_left
val u16_shift_left (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_left` (U32.v amount)})
val u16_shift_left (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_left` (U32.v amount)})
let u16_shift_left (x: U16.t) (amount: U32.t { U32.v amount <= 16 }) : Tot (y: U16.t { U16.v y == U16.v x `U.shift_left` U32.v amount }) = if amount = 16ul then 0us else x `U16.shift_left` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 58, "end_line": 1068, "start_col": 0, "start_line": 1064 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 16} -> y: FStar.UInt16.t {FStar.UInt16.v y == FStar.UInt.shift_left (FStar.UInt16.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt16.__uint_to_t", "Prims.bool", "FStar.UInt16.shift_left", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt16.n", "FStar.UInt16.v", "FSta...
[]
false
false
false
false
false
let u16_shift_left (x: U16.t) (amount: U32.t{U32.v amount <= 16}) : Tot (y: U16.t{U16.v y == (U16.v x) `U.shift_left` (U32.v amount)}) =
if amount = 16ul then 0us else x `U16.shift_left` amount
false
LowParse.BitFields.fst
LowParse.BitFields.u32_shift_left
val u32_shift_left (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_left` (U32.v amount)})
val u32_shift_left (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_left` (U32.v amount)})
let u32_shift_left (x: U32.t) (amount: U32.t { U32.v amount <= 32 }) : Tot (y: U32.t { U32.v y == U32.v x `U.shift_left` U32.v amount }) = if amount = 32ul then 0ul else x `U32.shift_left` amount
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 58, "end_line": 991, "start_col": 0, "start_line": 987 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 32} -> y: FStar.UInt32.t {FStar.UInt32.v y == FStar.UInt.shift_left (FStar.UInt32.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "Prims.bool", "FStar.UInt32.shift_left", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt32.n", "FStar.UInt.shift_left" ]
[]
false
false
false
false
false
let u32_shift_left (x: U32.t) (amount: U32.t{U32.v amount <= 32}) : Tot (y: U32.t{U32.v y == (U32.v x) `U.shift_left` (U32.v amount)}) =
if amount = 32ul then 0ul else x `U32.shift_left` amount
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq64_rhs
val bitfield_eq64_rhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{bitfield_eq64_lhs x lo hi == y <==> (get_bitfield64 x lo hi <: U64.t) == v})
val bitfield_eq64_rhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{bitfield_eq64_lhs x lo hi == y <==> (get_bitfield64 x lo hi <: U64.t) == v})
let bitfield_eq64_rhs (x: U64.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 64}) (v: U64.t { U64.v v < pow2 (hi - lo) }) : Tot (y: U64.t { bitfield_eq64_lhs x lo hi == y <==> (get_bitfield64 x lo hi <: U64.t) == v }) = [@inline_let] let _ = bitfield_eq_shift (U64.v x) lo hi (U64.v v) in v `u64_shift_left` U32.ui...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 37, "end_line": 939, "start_col": 0, "start_line": 932 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 64} -> v: FStar.UInt64.t{FStar.UInt64.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt64.t { LowParse.BitFields.bitfield_eq64_lhs x lo hi == y <==> LowParse.BitFields.get_bitfield64 x lo hi == v }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt64.v", "Prims.pow2", "Prims.op_Subtraction", "LowParse.BitFields.u64_shift_left", "FStar.UInt32.uint_to_t", "Prims.unit", "LowParse.BitFields.bitfield_eq_shift", "FStar.UI...
[]
false
false
false
false
false
let bitfield_eq64_rhs (x: U64.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 64}) (v: U64.t{U64.v v < pow2 (hi - lo)}) : Tot (y: U64.t{bitfield_eq64_lhs x lo hi == y <==> (get_bitfield64 x lo hi <: U64.t) == v}) =
[@@ inline_let ]let _ = bitfield_eq_shift (U64.v x) lo hi (U64.v v) in v `u64_shift_left` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.not_bitfield_mask8
val not_bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == not_bitfield_mask 8 lo hi})
val not_bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == not_bitfield_mask 8 lo hi})
let not_bitfield_mask8 (lo: nat) (hi: nat { lo <= hi /\ hi <= 8 }) : Tot (x: U8.t { U8.v x == not_bitfield_mask 8 lo hi }) = U8.lognot (bitfield_mask8 lo hi)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 34, "end_line": 1164, "start_col": 0, "start_line": 1163 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 8} -> x: FStar.UInt8.t{FStar.UInt8.v x == LowParse.BitFields.not_bitfield_mask 8 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt8.lognot", "LowParse.BitFields.bitfield_mask8", "FStar.UInt8.t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt8.v", "LowParse.BitFields.not_bitfield_mask" ]
[]
false
false
false
false
false
let not_bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == not_bitfield_mask 8 lo hi}) =
U8.lognot (bitfield_mask8 lo hi)
false
LowParse.BitFields.fst
LowParse.BitFields.u8_shift_right
val u8_shift_right (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_right` (U32.v amount)})
val u8_shift_right (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_right` (U32.v amount)})
let u8_shift_right (x: U8.t) (amount: U32.t { U32.v amount <= 8 }) : Tot (y: U8.t { U8.v y == U8.v x `U.shift_right` U32.v amount }) = let y = if amount = 8ul then 0uy else x `U8.shift_right` amount in y
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 1127, "start_col": 0, "start_line": 1120 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 8} -> y: FStar.UInt8.t {FStar.UInt8.v y == FStar.UInt.shift_right (FStar.UInt8.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt8.v", "FStar.UInt.shift_right", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt8.__uint_to_t", "Prims.bool", "FStar.UInt8.shift_right", ...
[]
false
false
false
false
false
let u8_shift_right (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_right` (U32.v amount)}) =
let y = if amount = 8ul then 0uy else x `U8.shift_right` amount in y
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq32_rhs
val bitfield_eq32_rhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{bitfield_eq32_lhs x lo hi == y <==> (get_bitfield32 x lo hi <: U32.t) == v})
val bitfield_eq32_rhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{bitfield_eq32_lhs x lo hi == y <==> (get_bitfield32 x lo hi <: U32.t) == v})
let bitfield_eq32_rhs (x: U32.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 32}) (v: U32.t { U32.v v < pow2 (hi - lo) }) : Tot (y: U32.t { bitfield_eq32_lhs x lo hi == y <==> (get_bitfield32 x lo hi <: U32.t) == v }) = [@inline_let] let _ = bitfield_eq_shift (U32.v x) lo hi (U32.v v) in v `u32_shift_left` U32.ui...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 37, "end_line": 1014, "start_col": 0, "start_line": 1007 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 32} -> v: FStar.UInt32.t{FStar.UInt32.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt32.t { LowParse.BitFields.bitfield_eq32_lhs x lo hi == y <==> LowParse.BitFields.get_bitfield32 x lo hi == v }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.pow2", "Prims.op_Subtraction", "LowParse.BitFields.u32_shift_left", "FStar.UInt32.uint_to_t", "Prims.unit", "LowParse.BitFields.bitfield_eq_shift", "FStar.UI...
[]
false
false
false
false
false
let bitfield_eq32_rhs (x: U32.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 32}) (v: U32.t{U32.v v < pow2 (hi - lo)}) : Tot (y: U32.t{bitfield_eq32_lhs x lo hi == y <==> (get_bitfield32 x lo hi <: U32.t) == v}) =
[@@ inline_let ]let _ = bitfield_eq_shift (U32.v x) lo hi (U32.v v) in v `u32_shift_left` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.uint64
val uint64 : uint_t 64 U64.t
val uint64 : uint_t 64 U64.t
let uint64 : uint_t 64 U64.t = { v = U64.v; uint_to_t = U64.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen64 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen64 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield64...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 1, "end_line": 1216, "start_col": 0, "start_line": 1204 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt...
{ "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
LowParse.BitFields.uint_t 64 FStar.UInt64.t
Prims.Tot
[ "total" ]
[]
[ "LowParse.BitFields.Mkuint_t", "FStar.UInt64.n", "FStar.UInt64.t", "FStar.UInt64.v", "FStar.UInt64.uint_to_t", "FStar.UInt.uint_t", "Prims.unit", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "LowParse.BitFields.get_bitfiel...
[]
false
false
false
false
false
let uint64:uint_t 64 U64.t =
{ v = U64.v; uint_to_t = U64.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen64 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen64 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield64 x lo hi); set_bitfield = (fu...
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield16
val get_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) lo hi})
val get_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) lo hi})
let get_bitfield16 (x: U16.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 16}) : Tot (y: U16.t { U16.v y == get_bitfield (U16.v x) lo hi }) = (x `U16.logand` bitfield_mask16 lo hi) `u16_shift_right` (U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 77, "end_line": 1057, "start_col": 0, "start_line": 1054 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> y: FStar.UInt16.t{FStar.UInt16.v y == LowParse.BitFields.get_bitfield (FStar.UInt16.v x) lo hi}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.u16_shift_right", "FStar.UInt16.logand", "LowParse.BitFields.bitfield_mask16", "FStar.UInt32.uint_to_t", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt16.n", "FStar.UInt16.v", "LowPars...
[]
false
false
false
false
false
let get_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) lo hi}) =
(x `U16.logand` (bitfield_mask16 lo hi)) `u16_shift_right` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_gen16
val get_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) (U32.v lo) (U32.v hi)})
val get_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) (U32.v lo) (U32.v hi)})
let get_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 16}) : Tot (y: U16.t { U16.v y == get_bitfield (U16.v x) (U32.v lo) (U32.v hi) }) = get_bitfield_eq_2 #16 (U16.v x) (U32.v lo) (U32.v hi); (* avoid integer promotion again *) let bf : U16.t = x `U16.shift_left` (16ul `U32...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 57, "end_line": 1100, "start_col": 0, "start_line": 1094 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 16} -> y: FStar.UInt16.t { FStar.UInt16.v y == LowParse.BitFields.get_bitfield (FStar.UInt16.v x) (FStar.UInt32.v lo) (FStar.UInt32.v hi) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt16.shift_right", "FStar.UInt32.add", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt16.shift_left", "Prims.unit", "LowParse.BitFields.ge...
[]
false
false
false
false
false
let get_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) : Tot (y: U16.t{U16.v y == get_bitfield (U16.v x) (U32.v lo) (U32.v hi)}) =
get_bitfield_eq_2 #16 (U16.v x) (U32.v lo) (U32.v hi); let bf:U16.t = x `U16.shift_left` (16ul `U32.sub` hi) in bf `U16.shift_right` ((16ul `U32.sub` hi) `U32.add` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_gen64
val set_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) (v: U64.t{U64.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) (U32.v lo) (U32.v hi) (U64.v v)})
val set_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) (v: U64.t{U64.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) (U32.v lo) (U32.v hi) (U64.v v)})
let set_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 64}) (v: U64.t { U64.v v < pow2 (U32.v hi - U32.v lo) }) : Tot (y: U64.t { U64.v y == set_bitfield (U64.v x) (U32.v lo) (U32.v hi) (U64.v v) }) = bitfield_mask_eq_2 64 (U32.v lo) (U32.v hi); (x `U64.logand` U64.lognot (((...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 159, "end_line": 956, "start_col": 0, "start_line": 951 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt64.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 64} -> v: FStar.UInt64.t{FStar.UInt64.v v < Prims.pow2 (FStar.UInt32.v hi - FStar.UInt32.v lo)} -> y: FStar.UInt64.t { FStar.UInt64.v y == LowParse.BitFields.s...
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt64.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt64.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt64.logor", "FStar.UInt64.logand", "FStar.UInt64.lognot", "FStar.UInt64.shift_left", "FStar...
[]
false
false
false
false
false
let set_bitfield_gen64 (x: U64.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 64}) (v: U64.t{U64.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U64.t{U64.v y == set_bitfield (U64.v x) (U32.v lo) (U32.v hi) (U64.v v)}) =
bitfield_mask_eq_2 64 (U32.v lo) (U32.v hi); (x `U64.logand` (U64.lognot (((U64.lognot 0uL) `U64.shift_right` (64ul `U32.sub` (hi `U32.sub` lo))) `U64.shift_left` lo))) `U64.logor` (v `U64.shift_left` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_mask8
val bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == bitfield_mask 8 lo hi})
val bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == bitfield_mask 8 lo hi})
let bitfield_mask8 (lo: nat) (hi: nat { lo <= hi /\ hi <= 8 }) : Tot (x: U8.t { U8.v x == bitfield_mask 8 lo hi }) = if lo = hi then 0uy else begin bitfield_mask_eq_2 8 lo hi; (U8.lognot 0uy `U8.shift_right` (8ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U8.shift_left` U32.uint_to_t lo end
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 1117, "start_col": 0, "start_line": 1111 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 8} -> x: FStar.UInt8.t{FStar.UInt8.v x == LowParse.BitFields.bitfield_mask 8 lo hi}
Prims.Tot
[ "total" ]
[]
[ "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_Equality", "FStar.UInt8.__uint_to_t", "Prims.bool", "FStar.UInt8.shift_left", "FStar.UInt8.shift_right", "FStar.UInt8.lognot", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt32.uint_to_t", "Prims.op_...
[]
false
false
false
false
false
let bitfield_mask8 (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) : Tot (x: U8.t{U8.v x == bitfield_mask 8 lo hi}) =
if lo = hi then 0uy else (bitfield_mask_eq_2 8 lo hi; ((U8.lognot 0uy) `U8.shift_right` (8ul `U32.sub` (U32.uint_to_t (hi - lo)))) `U8.shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_gen8
val set_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) (v: U8.t{U8.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) (U32.v lo) (U32.v hi) (U8.v v)})
val set_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) (v: U8.t{U8.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) (U32.v lo) (U32.v hi) (U8.v v)})
let set_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 8}) (v: U8.t { U8.v v < pow2 (U32.v hi - U32.v lo) }) : Tot (y: U8.t { U8.v y == set_bitfield (U8.v x) (U32.v lo) (U32.v hi) (U8.v v) }) = bitfield_mask_eq_2 8 (U32.v lo) (U32.v hi); (* NOTE: due to https://github.com/FStar...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 1153, "start_col": 0, "start_line": 1140 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 8} -> v: FStar.UInt8.t{FStar.UInt8.v v < Prims.pow2 (FStar.UInt32.v hi - FStar.UInt32.v lo)} -> y: FStar.UInt8.t { FStar.UInt8.v y == LowParse.BitFields.set_bit...
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt8.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt8.logor", "FStar.UInt8.shift_left", "FStar.UInt8.logand", "FStar.UInt8.lognot", "FStar.UInt8...
[]
false
false
false
false
false
let set_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) (v: U8.t{U8.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) (U32.v lo) (U32.v hi) (U8.v v)}) =
bitfield_mask_eq_2 8 (U32.v lo) (U32.v hi); let op0 = (U8.lognot 0uy) in let op1 = op0 `U8.shift_right` (8ul `U32.sub` (hi `U32.sub` lo)) in let op2 = op1 `U8.shift_left` lo in let op3 = U8.lognot op2 in let op4 = x `U8.logand` op3 in let op5 = v `U8.shift_left` lo in let op6 = op4 `U8.logor` op5 in op6
false
LowParse.BitFields.fst
LowParse.BitFields.uint32
val uint32 : uint_t 32 U32.t
val uint32 : uint_t 32 U32.t
let uint32 : uint_t 32 U32.t = { v = U32.v; uint_to_t = U32.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen32 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen32 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield32...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 1, "end_line": 1235, "start_col": 0, "start_line": 1223 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt...
{ "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
LowParse.BitFields.uint_t 32 FStar.UInt32.t
Prims.Tot
[ "total" ]
[]
[ "LowParse.BitFields.Mkuint_t", "FStar.UInt32.n", "FStar.UInt32.t", "FStar.UInt32.v", "FStar.UInt32.uint_to_t", "FStar.UInt.uint_t", "Prims.unit", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Prims.op_LessThanOrEqual", "LowParse.BitFields.get_bitfield_gen32", "Prims.eq2", "LowParse.Bit...
[]
false
false
false
false
false
let uint32:uint_t 32 U32.t =
{ v = U32.v; uint_to_t = U32.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen32 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen32 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield32 x lo hi); set_bitfield = (fu...
false
Hacl.Impl.K256.PointDouble.fst
Hacl.Impl.K256.PointDouble.point_double_no_alloc
val point_double_no_alloc (out p:point) (tmp:lbuffer uint64 (5ul *! nlimb)) : Stack unit (requires fun h -> live h out /\ live h p /\ live h tmp /\ eq_or_disjoint out p /\ disjoint out tmp /\ disjoint p tmp /\ point_inv h p) (ensures fun h0 _ h1 -> modifies (loc out |+| loc tmp) h0 h1 /\ point_inv h1 ou...
val point_double_no_alloc (out p:point) (tmp:lbuffer uint64 (5ul *! nlimb)) : Stack unit (requires fun h -> live h out /\ live h p /\ live h tmp /\ eq_or_disjoint out p /\ disjoint out tmp /\ disjoint p tmp /\ point_inv h p) (ensures fun h0 _ h1 -> modifies (loc out |+| loc tmp) h0 h1 /\ point_inv h1 ou...
let point_double_no_alloc out p tmp = let x1, y1, z1 = getx p, gety p, getz p in let x3, y3, z3 = getx out, gety out, getz out in let yy = sub tmp 0ul nlimb in let zz = sub tmp nlimb nlimb in let bzz3 = sub tmp (2ul *! nlimb) nlimb in let bzz9 = sub tmp (3ul *! nlimb) nlimb in let tmp = sub tmp (4ul *! n...
{ "file_name": "code/k256/Hacl.Impl.K256.PointDouble.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 16, "end_line": 145, "start_col": 0, "start_line": 117 }
module Hacl.Impl.K256.PointDouble open FStar.HyperStack open FStar.HyperStack.ST open FStar.Mul open Lib.IntTypes open Lib.Buffer module ST = FStar.HyperStack.ST module S = Spec.K256 module BL = Hacl.Spec.K256.Field52.Lemmas open Hacl.K256.Field open Hacl.Impl.K256.Point #set-options "--z3rlimit 300 --fuel 0 --if...
{ "checked_file": "/", "dependencies": [ "Spec.K256.fst.checked", "prims.fst.checked", "Lib.IntTypes.fsti.checked", "Lib.Buffer.fsti.checked", "Hacl.Spec.K256.Field52.Lemmas.fsti.checked", "Hacl.K256.Field.fsti.checked", "Hacl.Impl.K256.Point.fsti.checked", "FStar.UInt32.fsti.checked...
[ { "abbrev": false, "full_module": "Hacl.Impl.K256.Point", "short_module": null }, { "abbrev": false, "full_module": "Hacl.K256.Field", "short_module": null }, { "abbrev": true, "full_module": "Hacl.Spec.K256.Field52.Lemmas", "short_module": "BL" }, { "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
out: Hacl.Impl.K256.Point.point -> p: Hacl.Impl.K256.Point.point -> tmp: Lib.Buffer.lbuffer Lib.IntTypes.uint64 (5ul *! Hacl.K256.Field.nlimb) -> FStar.HyperStack.ST.Stack Prims.unit
FStar.HyperStack.ST.Stack
[]
[]
[ "Hacl.Impl.K256.Point.point", "Lib.Buffer.lbuffer", "Lib.IntTypes.uint64", "Lib.IntTypes.op_Star_Bang", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "FStar.UInt32.__uint_to_t", "Hacl.K256.Field.nlimb", "Hacl.K256.Field.felem", "Hacl.Impl.K256.PointDouble.calc_y3", "Prims.unit", "Hacl.K256.Field.fmu...
[]
false
true
false
false
false
let point_double_no_alloc out p tmp =
let x1, y1, z1 = getx p, gety p, getz p in let x3, y3, z3 = getx out, gety out, getz out in let yy = sub tmp 0ul nlimb in let zz = sub tmp nlimb nlimb in let bzz3 = sub tmp (2ul *! nlimb) nlimb in let bzz9 = sub tmp (3ul *! nlimb) nlimb in let tmp = sub tmp (4ul *! nlimb) nlimb in let h0 = ST.get () in fsqr yy y1; fsqr...
false
LowParse.BitFields.fst
LowParse.BitFields.u8_shift_left
val u8_shift_left (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_left` (U32.v amount)})
val u8_shift_left (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_left` (U32.v amount)})
let u8_shift_left (x: U8.t) (amount: U32.t { U32.v amount <= 8 }) : Tot (y: U8.t { U8.v y == U8.v x `U.shift_left` U32.v amount }) = let y = if amount = 8ul then 0uy else x `U8.shift_left` amount in y
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 1174, "start_col": 0, "start_line": 1167 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> amount: FStar.UInt32.t{FStar.UInt32.v amount <= 8} -> y: FStar.UInt8.t {FStar.UInt8.v y == FStar.UInt.shift_left (FStar.UInt8.v x) (FStar.UInt32.v amount)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "FStar.UInt32.t", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt32.v", "Prims.eq2", "FStar.UInt.uint_t", "FStar.UInt8.v", "FStar.UInt.shift_left", "Prims.op_Equality", "FStar.UInt32.__uint_to_t", "FStar.UInt8.__uint_to_t", "Prims.bool", "FStar.UInt8.shift_left", "F...
[]
false
false
false
false
false
let u8_shift_left (x: U8.t) (amount: U32.t{U32.v amount <= 8}) : Tot (y: U8.t{U8.v y == (U8.v x) `U.shift_left` (U32.v amount)}) =
let y = if amount = 8ul then 0uy else x `U8.shift_left` amount in y
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield8
val set_bitfield8 (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) lo hi (U8.v v)})
val set_bitfield8 (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) lo hi (U8.v v)})
let set_bitfield8 (x: U8.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 8}) (v: U8.t { U8.v v < pow2 (hi - lo) }) : Tot (y: U8.t { U8.v y == set_bitfield (U8.v x) lo hi (U8.v v) }) = if lo = hi then begin set_bitfield_empty #8 (U8.v x) lo (U8.v v); x end else set_bitfield_gen8 x (U32.uint_to_t lo) (U32.uint_to_...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 70, "end_line": 1184, "start_col": 0, "start_line": 1177 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 8} -> v: FStar.UInt8.t{FStar.UInt8.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt8.t {FStar.UInt8.v y == LowParse.BitFields.set_bitfield (FStar.UInt8.v x) lo hi (FStar.UInt8.v v)}
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt8.v", "Prims.pow2", "Prims.op_Subtraction", "Prims.op_Equality", "Prims.unit", "LowParse.BitFields.set_bitfield_empty", "Prims.bool", "LowParse.BitFields.set_bitfield_gen8"...
[]
false
false
false
false
false
let set_bitfield8 (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{U8.v y == set_bitfield (U8.v x) lo hi (U8.v v)}) =
if lo = hi then (set_bitfield_empty #8 (U8.v x) lo (U8.v v); x) else set_bitfield_gen8 x (U32.uint_to_t lo) (U32.uint_to_t hi) v
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq_shift
val bitfield_eq_shift (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) : Lemma (get_bitfield x lo hi == v <==> x `U.logand` (bitfield_mask tot lo hi) == v `U.shift_left` lo)
val bitfield_eq_shift (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) : Lemma (get_bitfield x lo hi == v <==> x `U.logand` (bitfield_mask tot lo hi) == v `U.shift_left` lo)
let bitfield_eq_shift (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) (v: ubitfield tot (hi - lo)) : Lemma (get_bitfield x lo hi == v <==> x `U.logand` bitfield_mask tot lo hi == v `U.shift_left` lo) = let y = x `U.logand` bitfield_mask tot lo hi in let z = get_bitfield x lo ...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 30, "end_line": 610, "start_col": 0, "start_line": 570 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": true, "full_module": "FStar.UInt",...
{ "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: FStar.UInt.uint_t tot -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= tot} -> v: LowParse.BitFields.ubitfield tot (hi - lo) -> FStar.Pervasives.Lemma (ensures LowParse.BitFields.get_bitfield x lo hi == v <==> FStar.UInt.logand x (LowParse.BitFields.bitfield_mask tot lo hi) == F...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "FStar.UInt.uint_t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "LowParse.BitFields.ubitfield", "Prims.op_Subtraction", "FStar.Classical.move_requires", "Prims.unit", "Prims.eq2", "Prims.squash", "Prims.Nil", "FStar.Pervasives.pattern", "LowParse.Bi...
[]
false
false
true
false
false
let bitfield_eq_shift (#tot: pos) (x: U.uint_t tot) (lo: nat) (hi: nat{lo <= hi /\ hi <= tot}) (v: ubitfield tot (hi - lo)) : Lemma (get_bitfield x lo hi == v <==> x `U.logand` (bitfield_mask tot lo hi) == v `U.shift_left` lo) =
let y = x `U.logand` (bitfield_mask tot lo hi) in let z = get_bitfield x lo hi in let w = v `U.shift_left` lo in let f () : Lemma (requires (y == w)) (ensures (z == v)) = eq_nth z v (fun i -> nth_logand x (bitfield_mask tot lo hi) i; nth_bitfield_mask tot lo hi i; nth_get_bitfield x lo...
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield16
val set_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) lo hi (U16.v v)})
val set_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) lo hi (U16.v v)})
let set_bitfield16 (x: U16.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 16}) (v: U16.t { U16.v v < pow2 (hi - lo) }) : Tot (y: U16.t { U16.v y == set_bitfield (U16.v x) lo hi (U16.v v) }) = (x `U16.logand` not_bitfield_mask16 lo hi) `U16.logor` (v `u16_shift_left` U32.uint_to_t lo)
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 94, "end_line": 1075, "start_col": 0, "start_line": 1071 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> v: FStar.UInt16.t{FStar.UInt16.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt16.t { FStar.UInt16.v y == LowParse.BitFields.set_bitfield (FStar.UInt16.v x) lo hi (FStar.UInt16.v v) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt16.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt16.logor", "FStar.UInt16.logand", "LowParse.BitFields.not_bitfield_mask16", "LowParse.BitFields.u16_shift_left", "F...
[]
false
false
false
false
false
let set_bitfield16 (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) lo hi (U16.v v)}) =
(x `U16.logand` (not_bitfield_mask16 lo hi)) `U16.logor` (v `u16_shift_left` (U32.uint_to_t lo))
false
LowParse.BitFields.fst
LowParse.BitFields.uint16
val uint16 : uint_t 16 U16.t
val uint16 : uint_t 16 U16.t
let uint16 : uint_t 16 U16.t = { v = U16.v; uint_to_t = U16.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen16 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen16 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield16...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 1, "end_line": 1254, "start_col": 0, "start_line": 1242 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt...
{ "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
LowParse.BitFields.uint_t 16 FStar.UInt16.t
Prims.Tot
[ "total" ]
[]
[ "LowParse.BitFields.Mkuint_t", "FStar.UInt16.n", "FStar.UInt16.t", "FStar.UInt16.v", "FStar.UInt16.uint_to_t", "FStar.UInt.uint_t", "Prims.unit", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "LowParse.BitFields.get_bitfiel...
[]
false
false
false
false
false
let uint16:uint_t 16 U16.t =
{ v = U16.v; uint_to_t = U16.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen16 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen16 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield16 x lo hi); set_bitfield = (fu...
false
LowParse.BitFields.fst
LowParse.BitFields.uint8
val uint8 : uint_t 8 U8.t
val uint8 : uint_t 8 U8.t
let uint8 : uint_t 8 U8.t = { v = U8.v; uint_to_t = U8.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen8 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen8 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield8 x lo hi...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 1, "end_line": 1273, "start_col": 0, "start_line": 1261 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt...
{ "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
LowParse.BitFields.uint_t 8 FStar.UInt8.t
Prims.Tot
[ "total" ]
[]
[ "LowParse.BitFields.Mkuint_t", "FStar.UInt8.n", "FStar.UInt8.t", "FStar.UInt8.v", "FStar.UInt8.uint_to_t", "FStar.UInt.uint_t", "Prims.unit", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "LowParse.BitFields.get_bitfield_ge...
[]
false
false
false
false
false
let uint8:uint_t 8 U8.t =
{ v = U8.v; uint_to_t = U8.uint_to_t; v_uint_to_t = (fun _ -> ()); uint_to_t_v = (fun _ -> ()); get_bitfield_gen = (fun x lo hi -> get_bitfield_gen8 x lo hi); set_bitfield_gen = (fun x lo hi z -> set_bitfield_gen8 x lo hi z); get_bitfield = (fun x lo hi -> get_bitfield8 x lo hi); set_bitfield = (fun x l...
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_gen8
val get_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) : Tot (y: U8.t{U8.v y == get_bitfield (U8.v x) (U32.v lo) (U32.v hi)})
val get_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) : Tot (y: U8.t{U8.v y == get_bitfield (U8.v x) (U32.v lo) (U32.v hi)})
let get_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 8}) : Tot (y: U8.t { U8.v y == get_bitfield (U8.v x) (U32.v lo) (U32.v hi) }) = get_bitfield_eq_2 #8 (U8.v x) (U32.v lo) (U32.v hi); (* NOTE: due to https://github.com/FStarLang/karamel/issues/102 I need to introduce explicit...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 5, "end_line": 1137, "start_col": 0, "start_line": 1130 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 8} -> y: FStar.UInt8.t { FStar.UInt8.v y == LowParse.BitFields.get_bitfield (FStar.UInt8.v x) (FStar.UInt32.v lo) (FStar.UInt32.v hi) }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt8.shift_right", "FStar.UInt32.add", "FStar.UInt32.sub", "FStar.UInt32.__uint_to_t", "FStar.UInt8.shift_left", "Prims.unit", "LowParse.BitFields.get_b...
[]
false
false
false
false
false
let get_bitfield_gen8 (x: U8.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 8}) : Tot (y: U8.t{U8.v y == get_bitfield (U8.v x) (U32.v lo) (U32.v hi)}) =
get_bitfield_eq_2 #8 (U8.v x) (U32.v lo) (U32.v hi); let op1 = x `U8.shift_left` (8ul `U32.sub` hi) in let op2 = op1 `U8.shift_right` ((8ul `U32.sub` hi) `U32.add` lo) in op2
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq16_rhs
val bitfield_eq16_rhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{bitfield_eq16_lhs x lo hi == y <==> (get_bitfield16 x lo hi <: U16.t) == v})
val bitfield_eq16_rhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{bitfield_eq16_lhs x lo hi == y <==> (get_bitfield16 x lo hi <: U16.t) == v})
let bitfield_eq16_rhs (x: U16.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 16}) (v: U16.t { U16.v v < pow2 (hi - lo) }) : Tot (y: U16.t { bitfield_eq16_lhs x lo hi == y <==> (get_bitfield16 x lo hi <: U16.t) == v }) = [@inline_let] let _ = bitfield_eq_shift (U16.v x) lo hi (U16.v v) in v `u16_shift_left` U32.ui...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 37, "end_line": 1091, "start_col": 0, "start_line": 1084 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 16} -> v: FStar.UInt16.t{FStar.UInt16.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt16.t { LowParse.BitFields.bitfield_eq16_lhs x lo hi == y <==> LowParse.BitFields.get_bitfield16 x lo hi == v }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt16.v", "Prims.pow2", "Prims.op_Subtraction", "LowParse.BitFields.u16_shift_left", "FStar.UInt32.uint_to_t", "Prims.unit", "LowParse.BitFields.bitfield_eq_shift", "FStar.UI...
[]
false
false
false
false
false
let bitfield_eq16_rhs (x: U16.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 16}) (v: U16.t{U16.v v < pow2 (hi - lo)}) : Tot (y: U16.t{bitfield_eq16_lhs x lo hi == y <==> (get_bitfield16 x lo hi <: U16.t) == v}) =
[@@ inline_let ]let _ = bitfield_eq_shift (U16.v x) lo hi (U16.v v) in v `u16_shift_left` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_gen16
val set_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) (v: U16.t{U16.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) (U32.v lo) (U32.v hi) (U16.v v)})
val set_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) (v: U16.t{U16.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) (U32.v lo) (U32.v hi) (U16.v v)})
let set_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 16}) (v: U16.t { U16.v v < pow2 (U32.v hi - U32.v lo) }) : Tot (y: U16.t { U16.v y == set_bitfield (U16.v x) (U32.v lo) (U32.v hi) (U16.v v) }) = bitfield_mask_eq_2 16 (U32.v lo) (U32.v hi); (x `U16.logand` U16.lognot (((...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 159, "end_line": 1108, "start_col": 0, "start_line": 1103 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt16.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 16} -> v: FStar.UInt16.t{FStar.UInt16.v v < Prims.pow2 (FStar.UInt32.v hi - FStar.UInt32.v lo)} -> y: FStar.UInt16.t { FStar.UInt16.v y == LowParse.BitFields.s...
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt16.t", "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "FStar.UInt16.v", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt16.logor", "FStar.UInt16.logand", "FStar.UInt16.lognot", "FStar.UInt16.shift_left", "FStar...
[]
false
false
false
false
false
let set_bitfield_gen16 (x: U16.t) (lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 16}) (v: U16.t{U16.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U16.t{U16.v y == set_bitfield (U16.v x) (U32.v lo) (U32.v hi) (U16.v v)}) =
bitfield_mask_eq_2 16 (U32.v lo) (U32.v hi); (x `U16.logand` (U16.lognot (((U16.lognot 0us) `U16.shift_right` (16ul `U32.sub` (hi `U32.sub` lo))) `U16.shift_left` lo))) `U16.logor` (v `U16.shift_left` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.bitfield_eq8_rhs
val bitfield_eq8_rhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{bitfield_eq8_lhs x lo hi == y <==> (get_bitfield8 x lo hi <: U8.t) == v})
val bitfield_eq8_rhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{bitfield_eq8_lhs x lo hi == y <==> (get_bitfield8 x lo hi <: U8.t) == v})
let bitfield_eq8_rhs (x: U8.t) (lo: nat) (hi: nat {lo <= hi /\ hi <= 8}) (v: U8.t { U8.v v < pow2 (hi - lo) }) : Tot (y: U8.t { bitfield_eq8_lhs x lo hi == y <==> (get_bitfield8 x lo hi <: U8.t) == v }) = [@inline_let] let _ = bitfield_eq_shift (U8.v x) lo hi (U8.v v) in v `u8_shift_left` U32.uint_to_t lo
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 36, "end_line": 1200, "start_col": 0, "start_line": 1193 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt8.t -> lo: Prims.nat -> hi: Prims.nat{lo <= hi /\ hi <= 8} -> v: FStar.UInt8.t{FStar.UInt8.v v < Prims.pow2 (hi - lo)} -> y: FStar.UInt8.t { LowParse.BitFields.bitfield_eq8_lhs x lo hi == y <==> LowParse.BitFields.get_bitfield8 x lo hi == v }
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt8.t", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "Prims.op_LessThan", "FStar.UInt8.v", "Prims.pow2", "Prims.op_Subtraction", "LowParse.BitFields.u8_shift_left", "FStar.UInt32.uint_to_t", "Prims.unit", "LowParse.BitFields.bitfield_eq_shift", "FStar.UInt8...
[]
false
false
false
false
false
let bitfield_eq8_rhs (x: U8.t) (lo: nat) (hi: nat{lo <= hi /\ hi <= 8}) (v: U8.t{U8.v v < pow2 (hi - lo)}) : Tot (y: U8.t{bitfield_eq8_lhs x lo hi == y <==> (get_bitfield8 x lo hi <: U8.t) == v}) =
[@@ inline_let ]let _ = bitfield_eq_shift (U8.v x) lo hi (U8.v v) in v `u8_shift_left` (U32.uint_to_t lo)
false
LowParse.BitFields.fst
LowParse.BitFields.set_bitfield_gen32
val set_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) (v: U32.t{U32.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) (U32.v lo) (U32.v hi) (U32.v v)})
val set_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) (v: U32.t{U32.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) (U32.v lo) (U32.v hi) (U32.v v)})
let set_bitfield_gen32 (x: U32.t) (lo: U32.t) (hi: U32.t {U32.v lo < U32.v hi /\ U32.v hi <= 32}) (v: U32.t { U32.v v < pow2 (U32.v hi - U32.v lo) }) : Tot (y: U32.t { U32.v y == set_bitfield (U32.v x) (U32.v lo) (U32.v hi) (U32.v v) }) = bitfield_mask_eq_2 32 (U32.v lo) (U32.v hi); (x `U32.logand` U32.lognot (((...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 159, "end_line": 1031, "start_col": 0, "start_line": 1026 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": true, "full_module": "FStar.UInt8", "short_module": "U8" }, { "abbrev": true, "full_module": "FStar.UInt16", "short_module": "U16" }, { "abbrev": true, "full_module": "FStar.UInt64", "short_module": "U64" }, { "abbrev": true, "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
x: FStar.UInt32.t -> lo: FStar.UInt32.t -> hi: FStar.UInt32.t{FStar.UInt32.v lo < FStar.UInt32.v hi /\ FStar.UInt32.v hi <= 32} -> v: FStar.UInt32.t{FStar.UInt32.v v < Prims.pow2 (FStar.UInt32.v hi - FStar.UInt32.v lo)} -> y: FStar.UInt32.t { FStar.UInt32.v y == LowParse.BitFields.s...
Prims.Tot
[ "total" ]
[]
[ "FStar.UInt32.t", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "FStar.UInt32.v", "Prims.op_LessThanOrEqual", "Prims.pow2", "Prims.op_Subtraction", "FStar.UInt32.logor", "FStar.UInt32.logand", "FStar.UInt32.lognot", "FStar.UInt32.shift_left", "FStar.UInt32.shift_right", "FStar.UInt32.__...
[]
false
false
false
false
false
let set_bitfield_gen32 (x lo: U32.t) (hi: U32.t{U32.v lo < U32.v hi /\ U32.v hi <= 32}) (v: U32.t{U32.v v < pow2 (U32.v hi - U32.v lo)}) : Tot (y: U32.t{U32.v y == set_bitfield (U32.v x) (U32.v lo) (U32.v hi) (U32.v v)}) =
bitfield_mask_eq_2 32 (U32.v lo) (U32.v hi); (x `U32.logand` (U32.lognot (((U32.lognot 0ul) `U32.shift_right` (32ul `U32.sub` (hi `U32.sub` lo))) `U32.shift_left` lo))) `U32.logor` (v `U32.shift_left` lo)
false
LowParse.BitFields.fst
LowParse.BitFields.get_bitfield_partition_2_gen
val get_bitfield_partition_2_gen (#tot: pos) (lo: nat) (mi: nat) (hi: nat { lo <= mi /\ mi <= hi /\ hi <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x lo mi == get_bitfield y lo mi /\ get_bitfield x mi hi == get_bitfield y mi hi )) (ensures ( get_bitfield x lo hi == get_bitf...
val get_bitfield_partition_2_gen (#tot: pos) (lo: nat) (mi: nat) (hi: nat { lo <= mi /\ mi <= hi /\ hi <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x lo mi == get_bitfield y lo mi /\ get_bitfield x mi hi == get_bitfield y mi hi )) (ensures ( get_bitfield x lo hi == get_bitf...
let get_bitfield_partition_2_gen (#tot: pos) (lo: nat) (mi: nat) (hi: nat { lo <= mi /\ mi <= hi /\ hi <= tot }) (x y: U.uint_t tot) : Lemma (requires ( get_bitfield x lo mi == get_bitfield y lo mi /\ get_bitfield x mi hi == get_bitfield y mi hi )) (ensures ( get_bitfield x lo hi == get_bitf...
{ "file_name": "src/lowparse/LowParse.BitFields.fst", "git_rev": "00217c4a89f5ba56002ba9aa5b4a9d5903bfe9fa", "git_url": "https://github.com/project-everest/everparse.git", "project_name": "everparse" }
{ "end_col": 3, "end_line": 660, "start_col": 0, "start_line": 630 }
module LowParse.BitFields module U = FStar.UInt module M = LowParse.Math open FStar.Mul inline_for_extraction let bitfield_mask (tot: pos) (lo: nat) (hi: nat { lo <= hi /\ hi <= tot }) : Tot (U.uint_t tot) = [@inline_let] let _ = M.pow2_le_compat tot hi; M.pow2_plus (hi - lo) lo in normalize_term ((pow2...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowParse.Math.fst.checked", "FStar.UInt8.fsti.checked", "FStar.UInt64.fsti.checked", "FStar.UInt32.fsti.checked", "FStar.UInt16.fsti.checked", "FStar.UInt.fsti.checked", "FStar.Pervasives.fsti.checked", "FStar.Mul.fst...
[ { "abbrev": false, "full_module": "FStar.Mul", "short_module": null }, { "abbrev": true, "full_module": "LowParse.Math", "short_module": "M" }, { "abbrev": true, "full_module": "FStar.UInt", "short_module": "U" }, { "abbrev": false, "full_module": "LowParse", ...
{ "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
lo: Prims.nat -> mi: Prims.nat -> hi: Prims.nat{lo <= mi /\ mi <= hi /\ hi <= tot} -> x: FStar.UInt.uint_t tot -> y: FStar.UInt.uint_t tot -> FStar.Pervasives.Lemma (requires LowParse.BitFields.get_bitfield x lo mi == LowParse.BitFields.get_bitfield y lo mi /\ LowParse.BitFi...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Prims.pos", "Prims.nat", "Prims.l_and", "Prims.b2t", "Prims.op_LessThanOrEqual", "FStar.UInt.uint_t", "LowParse.BitFields.eq_nth", "LowParse.BitFields.get_bitfield", "Prims.op_LessThan", "Prims.op_Subtraction", "LowParse.BitFields.nth_get_bitfield", "Prims.unit", "Prims.bool", "Prims.op_A...
[]
false
false
true
false
false
let get_bitfield_partition_2_gen (#tot: pos) (lo mi: nat) (hi: nat{lo <= mi /\ mi <= hi /\ hi <= tot}) (x y: U.uint_t tot) : Lemma (requires (get_bitfield x lo mi == get_bitfield y lo mi /\ get_bitfield x mi hi == get_bitfield y mi hi)) (ensures (get_bitfield x ...
eq_nth (get_bitfield x lo hi) (get_bitfield y lo hi) (fun i -> let a = nth (get_bitfield x lo hi) i in let b = nth (get_bitfield y lo hi) i in nth_get_bitfield x lo hi i; nth_get_bitfield y lo hi i; if i < hi - lo then if i < mi - lo then (nth_get_bitfie...
false
Vale.AES.X64.GCMdecryptOpt.fsti
Vale.AES.X64.GCMdecryptOpt.va_wp_Gcm_blocks_decrypt_stdcall
val va_wp_Gcm_blocks_decrypt_stdcall (win: bool) (alg: algorithm) (auth_b: buffer128) (auth_bytes auth_num: nat64) (keys_b iv_b: buffer128) (iv: supported_iv_LE) (hkeys_b abytes_b in128x6_b out128x6_b: buffer128) (len128x6_num: nat64) (in128_b out128_b: buffer128) ...
val va_wp_Gcm_blocks_decrypt_stdcall (win: bool) (alg: algorithm) (auth_b: buffer128) (auth_bytes auth_num: nat64) (keys_b iv_b: buffer128) (iv: supported_iv_LE) (hkeys_b abytes_b in128x6_b out128x6_b: buffer128) (len128x6_num: nat64) (in128_b out128_b: buffer128) ...
let va_wp_Gcm_blocks_decrypt_stdcall (win:bool) (alg:algorithm) (auth_b:buffer128) (auth_bytes:nat64) (auth_num:nat64) (keys_b:buffer128) (iv_b:buffer128) (iv:supported_iv_LE) (hkeys_b:buffer128) (abytes_b:buffer128) (in128x6_b:buffer128) (out128x6_b:buffer128) (len128x6_num:nat64) (in128_b:buffer128) (out128_b:b...
{ "file_name": "obj/Vale.AES.X64.GCMdecryptOpt.fsti", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 79, "end_line": 813, "start_col": 0, "start_line": 556 }
module Vale.AES.X64.GCMdecryptOpt open Vale.Def.Prop_s open Vale.Def.Opaque_s open FStar.Seq open Vale.Def.Words_s open Vale.Def.Words.Seq_s open Vale.Def.Types_s open Vale.Arch.Types open Vale.Arch.HeapImpl open Vale.AES.AES_s open Vale.AES.GCTR_s open Vale.AES.GCTR open Vale.AES.GCM open Vale.AES.GHash_s open Vale.AE...
{ "checked_file": "/", "dependencies": [ "Vale.X64.State.fsti.checked", "Vale.X64.Stack_i.fsti.checked", "Vale.X64.Stack.fsti.checked", "Vale.X64.QuickCodes.fsti.checked", "Vale.X64.QuickCode.fst.checked", "Vale.X64.Memory.fsti.checked", "Vale.X64.Machine_s.fst.checked", "Vale.X64.In...
[ { "abbrev": false, "full_module": "Vale.Lib.Basic", "short_module": null }, { "abbrev": false, "full_module": "Vale.AES.OptPublic", "short_module": null }, { "abbrev": false, "full_module": "Vale.AES.X64.GCMencryptOpt", "short_module": null }, { "abbrev": false, ...
{ "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
win: Prims.bool -> alg: Vale.AES.AES_common_s.algorithm -> auth_b: Vale.X64.Memory.buffer128 -> auth_bytes: Vale.X64.Memory.nat64 -> auth_num: Vale.X64.Memory.nat64 -> keys_b: Vale.X64.Memory.buffer128 -> iv_b: Vale.X64.Memory.buffer128 -> iv: Vale.AES.GCM_s.supported_iv_LE -> hkeys...
Prims.Tot
[ "total" ]
[]
[ "Prims.bool", "Vale.AES.AES_common_s.algorithm", "Vale.X64.Memory.buffer128", "Vale.X64.Memory.nat64", "Vale.AES.GCM_s.supported_iv_LE", "FStar.Seq.Base.seq", "Vale.X64.Memory.nat32", "Vale.X64.Decls.va_state", "Prims.unit", "Prims.l_and", "Prims.b2t", "Vale.X64.Decls.va_get_ok", "Vale.X64.C...
[]
false
false
false
true
true
let va_wp_Gcm_blocks_decrypt_stdcall (win: bool) (alg: algorithm) (auth_b: buffer128) (auth_bytes auth_num: nat64) (keys_b iv_b: buffer128) (iv: supported_iv_LE) (hkeys_b abytes_b in128x6_b out128x6_b: buffer128) (len128x6_num: nat64) (in128_b out128_b: buffer128) ...
(va_get_ok va_s0 /\ (let auth_ptr:(va_int_range 0 18446744073709551615) = va_if win (fun _ -> va_get_reg64 rRcx va_s0) (fun _ -> va_get_reg64 rRdi va_s0) in let auth_num_bytes:(va_int_range 0 18446744073709551615) = va_if win (fun _ -> va_get_reg64 rRdx va_s0) (fun _ -> va_get_reg64 rRsi va_s0) ...
false
Hacl.Impl.Lib.fst
Hacl.Impl.Lib.fill_elems_st
val fill_elems_st : Type
let fill_elems_st = #t:Type0 -> #a:Type0 -> h0:mem -> n:size_t -> output:lbuffer t n -> refl:(mem -> i:size_nat{i <= v n} -> GTot a) -> footprint:(i:size_nat{i <= v n} -> GTot (l:B.loc{B.loc_disjoint l (loc output) /\ B.address_liveness_insensitive_locs `B.loc_includes` l})) -> spec:(mem -> GTot (...
{ "file_name": "code/bignum/Hacl.Impl.Lib.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 57, "end_line": 44, "start_col": 0, "start_line": 20 }
module Hacl.Impl.Lib open FStar.HyperStack open FStar.HyperStack.ST open FStar.Mul open Lib.IntTypes open Lib.Buffer module ST = FStar.HyperStack.ST module B = LowStar.Buffer module LSeq = Lib.Sequence module Loops = Lib.LoopCombinators module S = Hacl.Spec.Lib #reset-options "--z3rlimit 50 --fuel 0 --ifuel 0"
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowStar.Buffer.fst.checked", "Lib.Sequence.fsti.checked", "Lib.Loops.fsti.checked", "Lib.LoopCombinators.fsti.checked", "Lib.IntTypes.fsti.checked", "Lib.Buffer.fsti.checked", "Hacl.Spec.Lib.fst.checked", "FStar.UInt3...
[ { "abbrev": true, "full_module": "Hacl.Spec.Lib", "short_module": "S" }, { "abbrev": true, "full_module": "Lib.LoopCombinators", "short_module": "Loops" }, { "abbrev": true, "full_module": "Lib.Sequence", "short_module": "LSeq" }, { "abbrev": true, "full_modul...
{ "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
Type
Prims.Tot
[ "total" ]
[]
[ "FStar.Monotonic.HyperStack.mem", "Lib.IntTypes.size_t", "Lib.Buffer.lbuffer", "Lib.IntTypes.size_nat", "Prims.b2t", "Prims.op_LessThanOrEqual", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "LowStar.Monotonic.Buffer.loc", "Prims.l_and", "LowStar.Monotonic.Buffer.loc_disjoint", "...
[]
false
false
false
true
true
let fill_elems_st =
#t: Type0 -> #a: Type0 -> h0: mem -> n: size_t -> output: lbuffer t n -> refl: (mem -> i: size_nat{i <= v n} -> GTot a) -> footprint: (i: size_nat{i <= v n} -> GTot (l: B.loc { B.loc_disjoint l (loc output) /\ B.add...
false
Hacl.Impl.Lib.fst
Hacl.Impl.Lib.lemma_eq_disjoint
val lemma_eq_disjoint: #a1:Type -> #a2:Type -> #a3:Type -> clen1:size_t -> clen2:size_t -> clen3:size_t -> b1:lbuffer a1 clen1 -> b2:lbuffer a2 clen2 -> b3:lbuffer a3 clen3 -> n:size_t{v n < v clen2 /\ v n < v clen1} -> h0:mem -> h1:mem -> Lemma (requires live h0 b1 /\ live h0 b2 /\ live...
val lemma_eq_disjoint: #a1:Type -> #a2:Type -> #a3:Type -> clen1:size_t -> clen2:size_t -> clen3:size_t -> b1:lbuffer a1 clen1 -> b2:lbuffer a2 clen2 -> b3:lbuffer a3 clen3 -> n:size_t{v n < v clen2 /\ v n < v clen1} -> h0:mem -> h1:mem -> Lemma (requires live h0 b1 /\ live h0 b2 /\ live...
let lemma_eq_disjoint #a1 #a2 #a3 clen1 clen2 clen3 b1 b2 b3 n h0 h1 = let b1s = gsub b1 0ul n in let b2s = gsub b2 0ul n in assert (modifies (loc b1s |+| loc b3) h0 h1); assert (disjoint b1 b2 ==> Seq.equal (as_seq h0 b2) (as_seq h1 b2)); assert (disjoint b1 b2 ==> Seq.equal (as_seq h0 b2s) (as_seq h1 b2s));...
{ "file_name": "code/bignum/Hacl.Impl.Lib.fst", "git_rev": "eb1badfa34c70b0bbe0fe24fe0f49fb1295c7872", "git_url": "https://github.com/project-everest/hacl-star.git", "project_name": "hacl-star" }
{ "end_col": 93, "end_line": 185, "start_col": 0, "start_line": 179 }
module Hacl.Impl.Lib open FStar.HyperStack open FStar.HyperStack.ST open FStar.Mul open Lib.IntTypes open Lib.Buffer module ST = FStar.HyperStack.ST module B = LowStar.Buffer module LSeq = Lib.Sequence module Loops = Lib.LoopCombinators module S = Hacl.Spec.Lib #reset-options "--z3rlimit 50 --fuel 0 --ifuel 0" in...
{ "checked_file": "/", "dependencies": [ "prims.fst.checked", "LowStar.Buffer.fst.checked", "Lib.Sequence.fsti.checked", "Lib.Loops.fsti.checked", "Lib.LoopCombinators.fsti.checked", "Lib.IntTypes.fsti.checked", "Lib.Buffer.fsti.checked", "Hacl.Spec.Lib.fst.checked", "FStar.UInt3...
[ { "abbrev": true, "full_module": "Hacl.Spec.Lib", "short_module": "S" }, { "abbrev": true, "full_module": "Lib.LoopCombinators", "short_module": "Loops" }, { "abbrev": true, "full_module": "Lib.Sequence", "short_module": "LSeq" }, { "abbrev": true, "full_modul...
{ "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
clen1: Lib.IntTypes.size_t -> clen2: Lib.IntTypes.size_t -> clen3: Lib.IntTypes.size_t -> b1: Lib.Buffer.lbuffer a1 clen1 -> b2: Lib.Buffer.lbuffer a2 clen2 -> b3: Lib.Buffer.lbuffer a3 clen3 -> n: Lib.IntTypes.size_t {Lib.IntTypes.v n < Lib.IntTypes.v clen2 /\ Lib.IntTypes.v ...
FStar.Pervasives.Lemma
[ "lemma" ]
[]
[ "Lib.IntTypes.size_t", "Lib.Buffer.lbuffer", "Prims.l_and", "Prims.b2t", "Prims.op_LessThan", "Lib.IntTypes.v", "Lib.IntTypes.U32", "Lib.IntTypes.PUB", "FStar.Monotonic.HyperStack.mem", "Prims._assert", "Prims.eq2", "FStar.Seq.Base.index", "Lib.Buffer.as_seq", "Lib.Buffer.MUT", "Lib.IntT...
[]
true
false
true
false
false
let lemma_eq_disjoint #a1 #a2 #a3 clen1 clen2 clen3 b1 b2 b3 n h0 h1 =
let b1s = gsub b1 0ul n in let b2s = gsub b2 0ul n in assert (modifies (loc b1s |+| loc b3) h0 h1); assert (disjoint b1 b2 ==> Seq.equal (as_seq h0 b2) (as_seq h1 b2)); assert (disjoint b1 b2 ==> Seq.equal (as_seq h0 b2s) (as_seq h1 b2s)); assert (Seq.index (as_seq h1 b2) (v n) == Seq.index (as_seq h1 (gsub b2 n (clen2...
false