Skip to content

Commit 6444e81

Browse files
willieyzhanno-becker
authored andcommitted
add symmetric note to all .ML HOL-LIGHT proofs
Signed-off-by: willieyz <willie.zhao@chelpis.com>
1 parent d370ad7 commit 6444e81

12 files changed

+36
-0
lines changed

proofs/hol_light/x86_64/proofs/mlkem_frombytes.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -446,6 +446,9 @@ let MLKEM_FROMBYTES_NOIBT_SUBROUTINE_CORRECT = prove(
446446
MAYCHANGE [RSP] ,, MAYCHANGE [memory :> bytes(r, 512)])`,
447447
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_frombytes_tmc MLKEM_FROMBYTES_CORRECT);;
448448

449+
(* NOTE: This must be kept in sync with the CBMC specification
450+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
451+
449452
let MLKEM_FROMBYTES_SUBROUTINE_CORRECT = prove(
450453
`!r a (l:(12 word) list) pc.
451454
aligned 32 a /\

proofs/hol_light/x86_64/proofs/mlkem_intt.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1213,6 +1213,9 @@ let MLKEM_INTT_NOIBT_SUBROUTINE_CORRECT = prove
12131213
CONV_TAC TWEAK_CONV THEN
12141214
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_intt_tmc (CONV_RULE TWEAK_CONV MLKEM_INTT_CORRECT));;
12151215

1216+
(* NOTE: This must be kept in sync with the CBMC specification
1217+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
1218+
12161219
let MLKEM_INTT_SUBROUTINE_CORRECT = prove
12171220
(`!a zetas (zetas_list:int16 list) x pc stackpointer returnaddress.
12181221
aligned 32 a /\

proofs/hol_light/x86_64/proofs/mlkem_mulcache_compute.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,6 +267,9 @@ let MLKEM_MULCACHE_COMPUTE_NOIBT_SUBROUTINE_CORRECT = prove(
267267
CONV_TAC TWEAK_CONV THEN
268268
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_mulcache_compute_tmc (CONV_RULE TWEAK_CONV MLKEM_MULCACHE_COMPUTE_CORRECT));;
269269

270+
(* NOTE: This must be kept in sync with the CBMC specification
271+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
272+
270273
let MLKEM_MULCACHE_COMPUTE_SUBROUTINE_CORRECT = prove(
271274
`!r a zetas (zetas_list:int16 list) x pc stackpointer returnaddress.
272275
aligned 32 r /\

proofs/hol_light/x86_64/proofs/mlkem_ntt.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1222,6 +1222,9 @@ let MLKEM_NTT_NOIBT_SUBROUTINE_CORRECT = prove
12221222
CONV_TAC TWEAK_CONV THEN
12231223
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_ntt_tmc (CONV_RULE TWEAK_CONV MLKEM_NTT_CORRECT));;
12241224

1225+
(* NOTE: This must be kept in sync with the CBMC specification
1226+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
1227+
12251228
let MLKEM_NTT_SUBROUTINE_CORRECT = prove
12261229
(`!a zetas (zetas_list:int16 list) x pc stackpointer returnaddress.
12271230
aligned 32 a /\

proofs/hol_light/x86_64/proofs/mlkem_poly_basemul_acc_montgomery_cached_k2.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1081,6 +1081,9 @@ let MLKEM_BASEMUL_K2_NOIBT_SUBROUTINE_CORRECT = prove(
10811081
MAYCHANGE [memory :> bytes(dst, 512)])`,
10821082
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_basemul_k2_tmc MLKEM_BASEMUL_K2_CORRECT);;
10831083

1084+
(* NOTE: This must be kept in sync with the CBMC specification
1085+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
1086+
10841087
let MLKEM_BASEMUL_K2_SUBROUTINE_CORRECT = prove(
10851088
`!src1 src2 src2t dst a0 b0 c0 d0 dz0 a1 b1 c1 d1 dz1 pc stackpointer returnaddress.
10861089
aligned 32 src1 /\

proofs/hol_light/x86_64/proofs/mlkem_poly_basemul_acc_montgomery_cached_k3.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1551,6 +1551,9 @@ let MLKEM_BASEMUL_K3_NOIBT_SUBROUTINE_CORRECT = prove(
15511551
MAYCHANGE [memory :> bytes(dst, 512)])`,
15521552
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_basemul_k3_tmc MLKEM_BASEMUL_K3_CORRECT);;
15531553

1554+
(* NOTE: This must be kept in sync with the CBMC specification
1555+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
1556+
15541557
let MLKEM_BASEMUL_K3_SUBROUTINE_CORRECT = prove(
15551558
`!src1 src2 src2t dst a0 b0 c0 d0 dz0 a1 b1 c1 d1 dz1 a2 b2 c2 d2 dz2 pc stackpointer returnaddress.
15561559
aligned 32 src1 /\

proofs/hol_light/x86_64/proofs/mlkem_poly_basemul_acc_montgomery_cached_k4.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2028,6 +2028,9 @@ let MLKEM_BASEMUL_K4_NOIBT_SUBROUTINE_CORRECT = prove(
20282028
MAYCHANGE [memory :> bytes(dst, 512)])`,
20292029
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_basemul_k4_tmc MLKEM_BASEMUL_K4_CORRECT);;
20302030

2031+
(* NOTE: This must be kept in sync with the CBMC specification
2032+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
2033+
20312034
let MLKEM_BASEMUL_K4_SUBROUTINE_CORRECT = prove(
20322035
`!src1 src2 src2t dst a0 b0 c0 d0 dz0 a1 b1 c1 d1 dz1 a2 b2 c2 d2 dz2 a3 b3 c3 d3 dz3 pc stackpointer returnaddress.
20332036
aligned 32 src1 /\

proofs/hol_light/x86_64/proofs/mlkem_reduce.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,9 @@ let MLKEM_REDUCE_NOIBT_SUBROUTINE_CORRECT = prove
421421
MAYCHANGE [memory :> bytes(a, 512)])`,
422422
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_reduce_tmc MLKEM_REDUCE_CORRECT);;
423423

424+
(* NOTE: This must be kept in sync with the CBMC specification
425+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
426+
424427
let MLKEM_REDUCE_SUBROUTINE_CORRECT = prove
425428
(`!a x pc stackpointer returnaddress.
426429
aligned 32 a /\

proofs/hol_light/x86_64/proofs/mlkem_rej_uniform.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -781,6 +781,9 @@ let MLKEM_REJ_UNIFORM_NOIBT_SUBROUTINE_CORRECT = prove
781781
X86_PROMOTE_RETURN_STACK_TAC mlkem_rej_uniform_tmc
782782
(CONV_RULE TWEAK_CONV MLKEM_REJ_UNIFORM_CORRECT) `[]` 528);;
783783

784+
(* NOTE: This must be kept in sync with the CBMC specification
785+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
786+
784787
let MLKEM_REJ_UNIFORM_SUBROUTINE_CORRECT = prove
785788
(`!res buf buflen table (inlist:(12 word)list) pc stackpointer returnaddress.
786789
12 divides val buflen /\

proofs/hol_light/x86_64/proofs/mlkem_tobytes.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,9 @@ let MLKEM_TOBYTES_NOIBT_SUBROUTINE_CORRECT = prove
404404
MAYCHANGE [memory :> bytes(r, 384)])`,
405405
X86_PROMOTE_RETURN_NOSTACK_TAC mlkem_tobytes_tmc MLKEM_TOBYTES_CORRECT);;
406406

407+
(* NOTE: This must be kept in sync with the CBMC specification
408+
* in mlkem/src/native/x86_64/src/arith_native_x86_64.h *)
409+
407410
let MLKEM_TOBYTES_SUBROUTINE_CORRECT = prove
408411
(`!r a (l:int16 list) pc.
409412
aligned 32 a /\

0 commit comments

Comments
 (0)