val va_qcode_Gcm_blocks
      (va_mods: va_mods_t)
      (alg: algorithm)
      (auth_b abytes_b in128_b out128_b inout_b iv_b: buffer128)
      (key: (seq nat32))
      (round_keys: (seq quad32))
      (keys_b hkeys_b: buffer128)
      (gcm_struct_b: buffer64)
    : (va_quickCode unit (va_code_Gcm_blocks alg))
let va_qcode_Gcm_blocks (va_mods:va_mods_t) (alg:algorithm) (auth_b:buffer128) (abytes_b:buffer128)
  (in128_b:buffer128) (out128_b:buffer128) (inout_b:buffer128) (iv_b:buffer128) (key:(seq nat32))
  (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (gcm_struct_b:buffer64) :
  (va_quickCode unit (va_code_Gcm_blocks alg)) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in let
    (abytes_ptr:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 0
    (va_get_mem_heaplet 3 va_s) in let (in128_ptr:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 1 (va_get_mem_heaplet 3 va_s) in let
    (out128_ptr:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 2
    (va_get_mem_heaplet 3 va_s) in let (len128:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 3 (va_get_mem_heaplet 3 va_s) in let
    (inout_ptr:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 4
    (va_get_mem_heaplet 3 va_s) in let (plain_num_bytes:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 5 (va_get_mem_heaplet 3 va_s) in let
    (auth_ptr:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 6
    (va_get_mem_heaplet 3 va_s) in let (auth_len:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 7 (va_get_mem_heaplet 3 va_s) in let
    (auth_num_bytes:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 8
    (va_get_mem_heaplet 3 va_s) in let (iv_ptr:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 9 (va_get_mem_heaplet 3 va_s) in let
    (keys_ptr:Vale.PPC64LE.Machine_s.nat64) = Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 10
    (va_get_mem_heaplet 3 va_s) in let (h_ptr:Vale.PPC64LE.Machine_s.nat64) =
    Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 11 (va_get_mem_heaplet 3 va_s) in let
    (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_old_s)) in va_QSeq
    va_range1
    "***** PRECONDITION NOT MET AT line 726 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 5) (va_op_reg_opr_reg 25)
    (11 `op_Multiply` 8) Secret gcm_struct_b 11) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 728 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25)
    (0 `op_Multiply` 8) Secret gcm_struct_b 0) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 729 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25)
    (6 `op_Multiply` 8) Secret gcm_struct_b 6) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 730 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25)
    (7 `op_Multiply` 8) Secret gcm_struct_b 7) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 731 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 9) (va_op_reg_opr_reg 25)
    (8 `op_Multiply` 8) Secret gcm_struct_b 8) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 732 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_blocks_auth auth_b abytes_b hkeys_b h_BE) (fun (va_s:va_state)
    (auth_quad_seq:(seq quad32)) -> let (y_0:quad32) = Vale.Def.Words_s.Mkfour
    #Vale.Def.Types_s.nat32 0 0 0 0 in let (y_auth_bytes:quad32) = va_get_vec 1 va_s in let
    (iv_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read iv_b 0 (va_get_mem_heaplet 2 va_old_s)) in let
    (ctr_BE_1:quad32) = iv_BE in let (ctr_BE_2:quad32) = Vale.AES.GCTR_BE_s.inc32 iv_BE 1 in
    va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 740 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 25)
    (9 `op_Multiply` 8) Secret gcm_struct_b 9) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 741 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 2) (va_op_vec_opr_vec 7)
    (va_op_reg_opr_reg 10) Public iv_b 0) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 743 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 21) (va_op_vec_opr_vec 7)) (fun (va_s:va_state) _ -> let
    (j0:quad32) = va_get_vec 7 va_s in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 745 column 17 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Load_one_lsb (va_op_vec_opr_vec 10)) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 747 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vadduwm (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 10)) (fun
    (va_s:va_state) _ -> let (auth_in:(seq quad32)) = auth_quad_seq in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 752 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 3) (va_op_reg_opr_reg 25)
    (1 `op_Multiply` 8) Secret gcm_struct_b 1) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 753 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25)
    (2 `op_Multiply` 8) Secret gcm_struct_b 2) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 754 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25)
    (3 `op_Multiply` 8) Secret gcm_struct_b 3) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 755 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25)
    (10 `op_Multiply` 8) Secret gcm_struct_b 10) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 756 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_blocks128 alg in128_b out128_b key round_keys keys_b hkeys_b h_BE) (fun
    (va_s:va_state) _ -> let (y_cipher128:quad32) = va_get_vec 1 va_s in let
    (va_arg115:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    out128_b) in let (va_arg114:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = auth_in in let
    (va_arg113:Vale.Def.Types_s.quad32) = y_cipher128 in let (va_arg112:Vale.Def.Types_s.quad32) =
    y_auth_bytes in let (va_arg111:Vale.Def.Types_s.quad32) = y_0 in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 758 column 36 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.lemma_ghash_incremental0_append h_BE va_arg111 va_arg112
    va_arg113 va_arg114 va_arg115) (let auth_in = FStar.Seq.Base.append #quad32 auth_in
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    out128_b)) in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 761 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25)
    (3 `op_Multiply` 8) Secret gcm_struct_b 3) (fun (va_s:va_state) _ -> let
    (va_arg110:Vale.Def.Types_s.nat64) = va_get_reg 7 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 762 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg110 4) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 763 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) 4) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 764 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25)
    (5 `op_Multiply` 8) Secret gcm_struct_b 5) (fun (va_s:va_state) _ -> let (y_inout:quad32) =
    y_cipher128 in let (plain_byte_seq:(seq quad32)) = empty_seq_quad32 in let
    (cipher_byte_seq:(seq quad32)) = empty_seq_quad32 in let (va_arg109:Vale.Def.Types_s.quad32) =
    va_get_vec 7 va_s in let (va_arg108:(FStar.Seq.Base.seq Vale.Def.Types_s.nat32)) = key in let
    (va_arg107:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = cipher_byte_seq in let
    (va_arg106:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = plain_byte_seq in let
    (va_arg105:Vale.AES.AES_common_s.algorithm) = alg in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 769 column 29 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCTR_BE.gctr_partial_opaque_init va_arg105 va_arg106 va_arg107
    va_arg108 va_arg109) (let (total_bytes:(va_int_at_least 0)) = FStar.Seq.Base.length #quad32
    auth_quad_seq `op_Multiply` 16 + plain_num_bytes in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 772 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_qIf va_mods (Cmp_gt (va_op_cmp_reg 6) (va_op_cmp_reg 7)) (qblock va_mods (fun
    (va_s:va_state) -> va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 774 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 3) (va_op_reg_opr_reg 25)
    (4 `op_Multiply` 8) Secret gcm_struct_b 4) (fun (va_s:va_state) _ -> va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 775 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Poly1305.Math.lemma_poly_bits64 ()) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 776 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 15) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 777 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_And (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 10)) (va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 779 column 24 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_extra_bytes alg inout_b key round_keys keys_b hkeys_b total_bytes y_0 auth_in
    h_BE) (fun (va_s:va_state) _ -> let y_inout = va_get_vec 1 va_s in let
    (raw_auth_quads:(FStar.Seq.Base.seq quad32)) = FStar.Seq.Base.append #quad32 auth_in
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_s)
    inout_b)) in va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 783 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    ((fun a_1582 (s_1583:(FStar.Seq.Base.seq a_1582)) (i_1584:Prims.nat) (j_1585:Prims.nat) -> let
    (j_1545:Prims.nat) = j_1585 in Prims.b2t (Prims.op_AmpAmp (Prims.op_LessThanOrEqual i_1584
    j_1545) (Prims.op_LessThanOrEqual j_1545 (FStar.Seq.Base.length #a_1582 s_1583))))
    Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_auth_quads)) 0
    total_bytes) (fun _ -> let (auth_input_bytes:(FStar.Seq.Base.seq Vale.Def.Words_s.nat8)) =
    FStar.Seq.Base.slice #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_auth_quads)) 0 total_bytes
    in let (padded_auth_bytes:(FStar.Seq.Base.seq Vale.Def.Types_s.nat8)) =
    Vale.AES.GCTR_BE_s.pad_to_128_bits auth_input_bytes in let auth_in =
    Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_auth_bytes in let plain_byte_seq =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5
    va_old_s) inout_b) in let cipher_byte_seq = Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_s) inout_b) in va_QEmpty ((auth_in,
    cipher_byte_seq, plain_byte_seq, y_inout)))))))))) (qblock va_mods (fun (va_s:va_state) ->
    va_QEmpty ((auth_in, cipher_byte_seq, plain_byte_seq, y_inout))))) (fun (va_s:va_state) va_g ->
    let ((auth_in:(seq quad32)), (cipher_byte_seq:(seq quad32)), (plain_byte_seq:(seq quad32)),
    (y_inout:quad32)) = va_g in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 791 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25)
    (8 `op_Multiply` 8) Secret gcm_struct_b 8) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 792 column 25 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_make_length_quad ()) (fun (va_s:va_state) _ -> let (length_quad32:quad32) =
    va_get_vec 9 va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 795 column 19 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_register hkeys_b h_BE y_inout) (fun (va_s:va_state) _ -> let (y_final:quad32) =
    va_get_vec 1 va_s in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 798 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 21)) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 801 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gctr_register alg key round_keys keys_b) (fun (va_s:va_state) _ -> let
    (va_arg104:Vale.Def.Types_s.quad32) = va_get_vec 1 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 803 column 40 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.be_seq_quad32_to_bytes_of_singleton va_arg104)
    (va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 804 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    ((fun (icb_661:Vale.Def.Types_s.quad32) (plain_662:Vale.Def.Types_s.quad32)
    (alg_663:Vale.AES.AES_common_s.algorithm) (key_664:(FStar.Seq.Base.seq Vale.Def.Types_s.nat32))
    (i_665:Prims.int) -> Vale.AES.AES_BE_s.is_aes_key_word alg_663 key_664) j0 y_final alg key 0)
    (fun _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 804 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 1 va_s == Vale.AES.GCTR_BE_s.gctr_encrypt_block j0 y_final alg key 0) (let
    (plain128:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_old_s) in128_b) in let (cipher128:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    in128_b) in va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 809 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (FStar.Seq.Base.length #quad32 plain_byte_seq == 0 ==> FStar.Seq.Base.equal
    #Vale.Def.Types_s.quad32 (FStar.Seq.Base.append #Vale.Def.Types_s.quad32 plain128
    plain_byte_seq) plain128) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 810 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (FStar.Seq.Base.length #quad32 cipher_byte_seq == 0 ==> FStar.Seq.Base.equal
    #Vale.Def.Types_s.quad32 (FStar.Seq.Base.append #Vale.Def.Types_s.quad32 cipher128
    cipher_byte_seq) cipher128) (let (va_arg103:Vale.Def.Types_s.quad32) =
    Vale.AES.GCTR_BE.inc32lite ctr_BE_2 len128 in let (va_arg102:Vale.Def.Types_s.quad32) =
    ctr_BE_2 in let (va_arg101:(FStar.Seq.Base.seq Vale.Def.Types_s.nat32)) = key in let
    (va_arg100:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = cipher_byte_seq in let
    (va_arg99:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = plain_byte_seq in let
    (va_arg98:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    out128_b) in let (va_arg97:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_old_s) in128_b) in let (va_arg96:Prims.nat) = FStar.Seq.Base.length #quad32 plain_byte_seq
    in let (va_arg95:Prims.nat) = len128 in let (va_arg94:Vale.AES.AES_common_s.algorithm) = alg in
    va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 812 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCTR_BE.lemma_gctr_partial_append va_arg94 va_arg95 va_arg96 va_arg97
    va_arg98 va_arg99 va_arg100 va_arg101 va_arg102 va_arg103) (let
    (va_arg93:Vale.Def.Types_s.quad32) = length_quad32 in let (va_arg92:(FStar.Seq.Base.seq
    Vale.Def.Types_s.quad32)) = auth_in in let (va_arg91:Vale.Def.Types_s.quad32) = y_final in let
    (va_arg90:Vale.Def.Types_s.quad32) = y_inout in let (va_arg89:Vale.Def.Types_s.quad32) = y_0 in
    va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 820 column 23 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.lemma_hash_append2 h_BE va_arg89 va_arg90 va_arg91 va_arg92
    va_arg93) (let auth_in = FStar.Seq.Base.append #quad32 auth_in (FStar.Seq.Base.create #quad32 1
    length_quad32) in let (va_arg88:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = auth_in in
    va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 822 column 31 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.ghash_incremental_to_ghash h_BE va_arg88) (va_QEmpty
    (())))))))))))))))))))))))))))))))))))))))
val va_qcode_Gcm_blocks
      (va_mods: va_mods_t)
      (alg: algorithm)
      (auth_b abytes_b in128_b out128_b inout_b iv_b: buffer128)
      (key: (seq nat32))
      (round_keys: (seq quad32))
      (keys_b hkeys_b: buffer128)
      (gcm_struct_b: buffer64)
    : (va_quickCode unit (va_code_Gcm_blocks alg))
let va_qcode_Gcm_blocks
      (va_mods: va_mods_t)
      (alg: algorithm)
      (auth_b abytes_b in128_b out128_b inout_b iv_b: buffer128)
      (key: (seq nat32))
      (round_keys: (seq quad32))
      (keys_b hkeys_b: buffer128)
      (gcm_struct_b: buffer64)
    : (va_quickCode unit (va_code_Gcm_blocks alg)) =
(qblock va_mods
    (fun (va_s: va_state) ->
        let va_old_s:va_state = va_s in
        let abytes_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 0 (va_get_mem_heaplet 3 va_s)
        in
        let in128_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 1 (va_get_mem_heaplet 3 va_s)
        in
        let out128_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 2 (va_get_mem_heaplet 3 va_s)
        in
        let len128:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 3 (va_get_mem_heaplet 3 va_s)
        in
        let inout_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 4 (va_get_mem_heaplet 3 va_s)
        in
        let plain_num_bytes:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 5 (va_get_mem_heaplet 3 va_s)
        in
        let auth_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 6 (va_get_mem_heaplet 3 va_s)
        in
        let auth_len:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 7 (va_get_mem_heaplet 3 va_s)
        in
        let auth_num_bytes:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 8 (va_get_mem_heaplet 3 va_s)
        in
        let iv_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 9 (va_get_mem_heaplet 3 va_s)
        in
        let keys_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 10 (va_get_mem_heaplet 3 va_s)
        in
        let h_ptr:Vale.PPC64LE.Machine_s.nat64 =
          Vale.PPC64LE.Decls.buffer64_read gcm_struct_b 11 (va_get_mem_heaplet 3 va_s)
        in
        let h_BE:Vale.Def.Types_s.quad32 =
          Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b
                2
                (va_get_mem_heaplet 0 va_old_s))
        in
        va_QSeq va_range1
          "***** PRECONDITION NOT MET AT line 726 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
          (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
              (va_op_reg_opr_reg 5)
              (va_op_reg_opr_reg 25)
              (11 `op_Multiply` 8)
              Secret
              gcm_struct_b
              11)
          (va_QSeq va_range1
              "***** PRECONDITION NOT MET AT line 728 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
              (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
                  (va_op_reg_opr_reg 4)
                  (va_op_reg_opr_reg 25)
                  (0 `op_Multiply` 8)
                  Secret
                  gcm_struct_b
                  0)
              (va_QSeq va_range1
                  "***** PRECONDITION NOT MET AT line 729 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                  (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
                      (va_op_reg_opr_reg 7)
                      (va_op_reg_opr_reg 25)
                      (6 `op_Multiply` 8)
                      Secret
                      gcm_struct_b
                      6)
                  (va_QSeq va_range1
                      "***** PRECONDITION NOT MET AT line 730 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                      (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
                          (va_op_reg_opr_reg 6)
                          (va_op_reg_opr_reg 25)
                          (7 `op_Multiply` 8)
                          Secret
                          gcm_struct_b
                          7)
                      (va_QSeq va_range1
                          "***** PRECONDITION NOT MET AT line 731 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                          (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
                              (va_op_reg_opr_reg 9)
                              (va_op_reg_opr_reg 25)
                              (8 `op_Multiply` 8)
                              Secret
                              gcm_struct_b
                              8)
                          (va_QBind va_range1
                              "***** PRECONDITION NOT MET AT line 732 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                              (va_quick_Gcm_blocks_auth auth_b abytes_b hkeys_b h_BE)
                              (fun (va_s: va_state) (auth_quad_seq: (seq quad32)) ->
                                  let y_0:quad32 =
                                    Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0 0 0
                                  in
                                  let y_auth_bytes:quad32 = va_get_vec 1 va_s in
                                  let iv_BE:Vale.Def.Types_s.quad32 =
                                    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read
                                          iv_b
                                          0
                                          (va_get_mem_heaplet 2 va_old_s))
                                  in
                                  let ctr_BE_1:quad32 = iv_BE in
                                  let ctr_BE_2:quad32 = Vale.AES.GCTR_BE_s.inc32 iv_BE 1 in
                                  va_QSeq va_range1
                                    "***** PRECONDITION NOT MET AT line 740 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet 3)
                                        (va_op_reg_opr_reg 10)
                                        (va_op_reg_opr_reg 25)
                                        (9 `op_Multiply` 8)
                                        Secret
                                        gcm_struct_b
                                        9)
                                    (va_QSeq va_range1
                                        "***** PRECONDITION NOT MET AT line 741 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                        (va_quick_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 2
                                            )
                                            (va_op_vec_opr_vec 7)
                                            (va_op_reg_opr_reg 10)
                                            Public
                                            iv_b
                                            0)
                                        (va_QBind va_range1
                                            "***** PRECONDITION NOT MET AT line 743 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                            (va_quick_Vmr (va_op_vec_opr_vec 21)
                                                (va_op_vec_opr_vec 7))
                                            (fun (va_s: va_state) _ ->
                                                let j0:quad32 = va_get_vec 7 va_s in
                                                va_QSeq va_range1
                                                  "***** PRECONDITION NOT MET AT line 745 column 17 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                  (va_quick_Load_one_lsb (va_op_vec_opr_vec 10))
                                                  (va_QBind va_range1
                                                      "***** PRECONDITION NOT MET AT line 747 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                      (va_quick_Vadduwm (va_op_vec_opr_vec 7)
                                                          (va_op_vec_opr_vec 7)
                                                          (va_op_vec_opr_vec 10))
                                                      (fun (va_s: va_state) _ ->
                                                          let auth_in:(seq quad32) =
                                                            auth_quad_seq
                                                          in
                                                          va_QSeq va_range1
                                                            "***** PRECONDITION NOT MET AT line 752 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                            (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet
                                                                    3)
                                                                (va_op_reg_opr_reg 3)
                                                                (va_op_reg_opr_reg 25)
                                                                (1 `op_Multiply` 8)
                                                                Secret
                                                                gcm_struct_b
                                                                1)
                                                            (va_QSeq va_range1
                                                                "***** PRECONDITION NOT MET AT line 753 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet
                                                                        3)
                                                                    (va_op_reg_opr_reg 7)
                                                                    (va_op_reg_opr_reg 25)
                                                                    (2 `op_Multiply` 8)
                                                                    Secret
                                                                    gcm_struct_b
                                                                    2)
                                                                (va_QSeq va_range1
                                                                    "***** PRECONDITION NOT MET AT line 754 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                    (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet
                                                                            3)
                                                                        (va_op_reg_opr_reg 6)
                                                                        (va_op_reg_opr_reg 25)
                                                                        (3 `op_Multiply` 8)
                                                                        Secret
                                                                        gcm_struct_b
                                                                        3)
                                                                    (va_QSeq va_range1
                                                                        "***** PRECONDITION NOT MET AT line 755 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                        (va_quick_MemLoad64 (va_op_heaplet_mem_heaplet
                                                                                3)
                                                                            (va_op_reg_opr_reg 4)
                                                                            (va_op_reg_opr_reg 25)
                                                                            (10 `op_Multiply` 8)
                                                                            Secret
                                                                            gcm_struct_b
                                                                            10)
                                                                        (va_QBind va_range1
                                                                            "***** PRECONDITION NOT MET AT line 756 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                            (va_quick_Gcm_blocks128 alg
                                                                                in128_b
                                                                                out128_b
                                                                                key
                                                                                round_keys
                                                                                keys_b
                                                                                hkeys_b
                                                                                h_BE)
                                                                            (fun
                                                                                (va_s: va_state)
                                                                                _
                                                                                ->
                                                                                let y_cipher128:quad32
                                                                                =
                                                                                  va_get_vec 1 va_s
                                                                                in
                                                                                let va_arg115:(FStar.Seq.Base.seq
                                                                                    Vale.Def.Types_s.quad32
                                                                                  ) =
                                                                                  Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                    (Vale.PPC64LE.Decls.s128
                                                                                        (va_get_mem_heaplet
                                                                                            1
                                                                                            va_s)
                                                                                        out128_b)
                                                                                in
                                                                                let va_arg114:(FStar.Seq.Base.seq
                                                                                    Vale.Def.Types_s.quad32
                                                                                  ) =
                                                                                  auth_in
                                                                                in
                                                                                let va_arg113:Vale.Def.Types_s.quad32
                                                                                =
                                                                                  y_cipher128
                                                                                in
                                                                                let va_arg112:Vale.Def.Types_s.quad32
                                                                                =
                                                                                  y_auth_bytes
                                                                                in
                                                                                let va_arg111:Vale.Def.Types_s.quad32
                                                                                =
                                                                                  y_0
                                                                                in
                                                                                va_qPURE va_range1
                                                                                  "***** PRECONDITION NOT MET AT line 758 column 36 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                  (fun (_: unit) ->
                                                                                      Vale.AES.GHash_BE.lemma_ghash_incremental0_append
                                                                                        h_BE
                                                                                        va_arg111
                                                                                        va_arg112
                                                                                        va_arg113
                                                                                        va_arg114
                                                                                        va_arg115)
                                                                                  (let auth_in =
                                                                                      FStar.Seq.Base.append
                                                                                        #quad32
                                                                                        auth_in
                                                                                        (Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                            (Vale.PPC64LE.Decls.s128
                                                                                                (va_get_mem_heaplet
                                                                                                    1
                                                                                                    va_s
                                                                                                  )
                                                                                                out128_b
                                                                                              ))
                                                                                    in
                                                                                    va_QBind va_range1
                                                                                      "***** PRECONDITION NOT MET AT line 761 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                      (va_quick_MemLoad64
                                                                                          (va_op_heaplet_mem_heaplet
                                                                                              3)
                                                                                          (va_op_reg_opr_reg
                                                                                              7)
                                                                                          (va_op_reg_opr_reg
                                                                                              25)
                                                                                          (3
                                                                                            `op_Multiply`
                                                                                            8)
                                                                                          Secret
                                                                                          gcm_struct_b
                                                                                          3)
                                                                                      (fun
                                                                                          (va_s:
                                                                                            va_state
                                                                                          )
                                                                                          _
                                                                                          ->
                                                                                          let
                                                                                          va_arg110:Vale.Def.Types_s.nat64
                                                                                          =
                                                                                            va_get_reg
                                                                                              7
                                                                                              va_s
                                                                                          in
                                                                                          va_qPURE va_range1
                                                                                            "***** PRECONDITION NOT MET AT line 762 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                            (fun
                                                                                                (_:
                                                                                                  unit
                                                                                                )
                                                                                                ->
                                                                                                Vale.AES.Types_helpers.lemma_ishl_64
                                                                                                  va_arg110
                                                                                                  4)
                                                                                            (va_QSeq
                                                                                                va_range1
                                                                                                "***** PRECONDITION NOT MET AT line 763 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                (va_quick_Sl64Imm
                                                                                                    (
                                                                                                      va_op_reg_opr_reg
                                                                                                        7

                                                                                                    )
                                                                                                    (
                                                                                                      va_op_reg_opr_reg
                                                                                                        7

                                                                                                    )
                                                                                                    4
                                                                                                  )
                                                                                                (va_QBind
                                                                                                    va_range1
                                                                                                    "***** PRECONDITION NOT MET AT line 764 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                    (
                                                                                                      va_quick_MemLoad64
                                                                                                        (
                                                                                                          va_op_heaplet_mem_heaplet
                                                                                                            3

                                                                                                        )
                                                                                                        (
                                                                                                          va_op_reg_opr_reg
                                                                                                            6

                                                                                                        )
                                                                                                        (
                                                                                                          va_op_reg_opr_reg
                                                                                                            25

                                                                                                        )
                                                                                                        (
                                                                                                          5
                                                                                                          `op_Multiply`
                                                                                                          8
                                                                                                        )
                                                                                                        Secret
                                                                                                        gcm_struct_b
                                                                                                        5

                                                                                                    )
                                                                                                    (
                                                                                                      fun
                                                                                                        (
                                                                                                          va_s:
                                                                                                          va_state
                                                                                                        )
                                                                                                        _
                                                                                                        ->
                                                                                                        let
                                                                                                        y_inout:quad32
                                                                                                        =
                                                                                                          y_cipher128
                                                                                                        in
                                                                                                        let
                                                                                                        plain_byte_seq:(
                                                                                                          seq
                                                                                                            quad32

                                                                                                        )
                                                                                                        =
                                                                                                          empty_seq_quad32
                                                                                                        in
                                                                                                        let
                                                                                                        cipher_byte_seq:(
                                                                                                          seq
                                                                                                            quad32

                                                                                                        )
                                                                                                        =
                                                                                                          empty_seq_quad32
                                                                                                        in
                                                                                                        let
                                                                                                        va_arg109:Vale.Def.Types_s.quad32
                                                                                                        =
                                                                                                          va_get_vec
                                                                                                            7
                                                                                                            va_s

                                                                                                        in
                                                                                                        let
                                                                                                        va_arg108:(
                                                                                                          FStar.Seq.Base.seq
                                                                                                            Vale.Def.Types_s.nat32

                                                                                                        )
                                                                                                        =
                                                                                                          key
                                                                                                        in
                                                                                                        let
                                                                                                        va_arg107:(
                                                                                                          FStar.Seq.Base.seq
                                                                                                            Vale.Def.Types_s.quad32

                                                                                                        )
                                                                                                        =
                                                                                                          cipher_byte_seq
                                                                                                        in
                                                                                                        let
                                                                                                        va_arg106:(
                                                                                                          FStar.Seq.Base.seq
                                                                                                            Vale.Def.Types_s.quad32

                                                                                                        )
                                                                                                        =
                                                                                                          plain_byte_seq
                                                                                                        in
                                                                                                        let
                                                                                                        va_arg105:Vale.AES.AES_common_s.algorithm
                                                                                                        =
                                                                                                          alg
                                                                                                        in
                                                                                                        va_qPURE
                                                                                                          va_range1
                                                                                                          "***** PRECONDITION NOT MET AT line 769 column 29 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                          (
                                                                                                            fun
                                                                                                              (
                                                                                                                _:
                                                                                                                unit
                                                                                                              )
                                                                                                              ->
                                                                                                              Vale.AES.GCTR_BE.gctr_partial_opaque_init
                                                                                                                va_arg105
                                                                                                                va_arg106
                                                                                                                va_arg107
                                                                                                                va_arg108
                                                                                                                va_arg109

                                                                                                          )
                                                                                                          (
                                                                                                            let
                                                                                                            total_bytes:(
                                                                                                              va_int_at_least
                                                                                                                0

                                                                                                            )
                                                                                                            =
                                                                                                              (
                                                                                                                FStar.Seq.Base.length
                                                                                                                  #quad32
                                                                                                                  auth_quad_seq

                                                                                                              )
                                                                                                              `op_Multiply`
                                                                                                              16 +
                                                                                                              plain_num_bytes
                                                                                                            in
                                                                                                            va_QBind
                                                                                                              va_range1
                                                                                                              "***** PRECONDITION NOT MET AT line 772 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                              (
                                                                                                                va_qIf
                                                                                                                  va_mods
                                                                                                                  (
                                                                                                                    Cmp_gt
                                                                                                                      (
                                                                                                                        va_op_cmp_reg
                                                                                                                          6

                                                                                                                      )
                                                                                                                      (
                                                                                                                        va_op_cmp_reg
                                                                                                                          7

                                                                                                                      )
                                                                                                                  )
                                                                                                                  (
                                                                                                                    qblock
                                                                                                                      va_mods
                                                                                                                      (
                                                                                                                        fun
                                                                                                                          (
                                                                                                                            va_s:
                                                                                                                            va_state
                                                                                                                          )
                                                                                                                          ->
                                                                                                                          va_QBind
                                                                                                                            va_range1
                                                                                                                            "***** PRECONDITION NOT MET AT line 774 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                            (
                                                                                                                              va_quick_MemLoad64
                                                                                                                                (
                                                                                                                                  va_op_heaplet_mem_heaplet
                                                                                                                                    3

                                                                                                                                )
                                                                                                                                (
                                                                                                                                  va_op_reg_opr_reg
                                                                                                                                    3

                                                                                                                                )
                                                                                                                                (
                                                                                                                                  va_op_reg_opr_reg
                                                                                                                                    25

                                                                                                                                )
                                                                                                                                (
                                                                                                                                  4
                                                                                                                                  `op_Multiply`
                                                                                                                                  8
                                                                                                                                )
                                                                                                                                Secret
                                                                                                                                gcm_struct_b
                                                                                                                                4

                                                                                                                            )
                                                                                                                            (
                                                                                                                              fun
                                                                                                                                (
                                                                                                                                  va_s:
                                                                                                                                  va_state
                                                                                                                                )
                                                                                                                                _
                                                                                                                                ->
                                                                                                                                va_qPURE
                                                                                                                                  va_range1
                                                                                                                                  "***** PRECONDITION NOT MET AT line 775 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                  (
                                                                                                                                    fun
                                                                                                                                      (
                                                                                                                                        _:
                                                                                                                                        unit
                                                                                                                                      )
                                                                                                                                      ->
                                                                                                                                      Vale.Poly1305.Math.lemma_poly_bits64
                                                                                                                                        ()

                                                                                                                                  )
                                                                                                                                  (
                                                                                                                                    va_QSeq
                                                                                                                                      va_range1
                                                                                                                                      "***** PRECONDITION NOT MET AT line 776 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                      (
                                                                                                                                        va_quick_LoadImm64
                                                                                                                                          (
                                                                                                                                            va_op_reg_opr_reg
                                                                                                                                              10

                                                                                                                                          )
                                                                                                                                          15

                                                                                                                                      )
                                                                                                                                      (
                                                                                                                                        va_QSeq
                                                                                                                                          va_range1
                                                                                                                                          "***** PRECONDITION NOT MET AT line 777 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                          (
                                                                                                                                            va_quick_And
                                                                                                                                              (
                                                                                                                                                va_op_reg_opr_reg
                                                                                                                                                  8

                                                                                                                                              )
                                                                                                                                              (
                                                                                                                                                va_op_reg_opr_reg
                                                                                                                                                  6

                                                                                                                                              )
                                                                                                                                              (
                                                                                                                                                va_op_reg_opr_reg
                                                                                                                                                  10

                                                                                                                                              )

                                                                                                                                          )
                                                                                                                                          (
                                                                                                                                            va_QBind
                                                                                                                                              va_range1
                                                                                                                                              "***** PRECONDITION NOT MET AT line 779 column 24 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                              (
                                                                                                                                                va_quick_Gcm_extra_bytes
                                                                                                                                                  alg
                                                                                                                                                  inout_b
                                                                                                                                                  key
                                                                                                                                                  round_keys
                                                                                                                                                  keys_b
                                                                                                                                                  hkeys_b
                                                                                                                                                  total_bytes
                                                                                                                                                  y_0
                                                                                                                                                  auth_in
                                                                                                                                                  h_BE

                                                                                                                                              )
                                                                                                                                              (
                                                                                                                                                fun
                                                                                                                                                  (
                                                                                                                                                    va_s:
                                                                                                                                                    va_state
                                                                                                                                                  )
                                                                                                                                                  _
                                                                                                                                                  ->
                                                                                                                                                  let
                                                                                                                                                  y_inout
                                                                                                                                                  =
                                                                                                                                                    va_get_vec
                                                                                                                                                      1
                                                                                                                                                      va_s

                                                                                                                                                  in
                                                                                                                                                  let
                                                                                                                                                  raw_auth_quads:(
                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                      quad32

                                                                                                                                                  )
                                                                                                                                                  =
                                                                                                                                                    FStar.Seq.Base.append
                                                                                                                                                      #quad32
                                                                                                                                                      auth_in
                                                                                                                                                      (
                                                                                                                                                        Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                          (
                                                                                                                                                            Vale.PPC64LE.Decls.s128
                                                                                                                                                              (
                                                                                                                                                                va_get_mem_heaplet
                                                                                                                                                                  5
                                                                                                                                                                  va_s

                                                                                                                                                              )
                                                                                                                                                              inout_b

                                                                                                                                                          )

                                                                                                                                                      )

                                                                                                                                                  in
                                                                                                                                                  va_qAssertSquash
                                                                                                                                                    va_range1
                                                                                                                                                    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 783 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                    (
                                                                                                                                                      (
                                                                                                                                                        fun
                                                                                                                                                          a_1582
                                                                                                                                                          (
                                                                                                                                                            s_1583:
                                                                                                                                                            (
                                                                                                                                                              FStar.Seq.Base.seq
                                                                                                                                                                a_1582

                                                                                                                                                            )
                                                                                                                                                          )
                                                                                                                                                          (
                                                                                                                                                            i_1584:
                                                                                                                                                            Prims.nat
                                                                                                                                                          )
                                                                                                                                                          (
                                                                                                                                                            j_1585:
                                                                                                                                                            Prims.nat
                                                                                                                                                          )
                                                                                                                                                          ->
                                                                                                                                                          let
                                                                                                                                                          j_1545:Prims.nat
                                                                                                                                                          =
                                                                                                                                                            j_1585
                                                                                                                                                          in
                                                                                                                                                          Prims.b2t
                                                                                                                                                            (
                                                                                                                                                              Prims.op_AmpAmp
                                                                                                                                                                (
                                                                                                                                                                  Prims.op_LessThanOrEqual
                                                                                                                                                                    i_1584
                                                                                                                                                                    j_1545

                                                                                                                                                                )
                                                                                                                                                                (
                                                                                                                                                                  Prims.op_LessThanOrEqual
                                                                                                                                                                    j_1545
                                                                                                                                                                    (
                                                                                                                                                                      FStar.Seq.Base.length
                                                                                                                                                                        #a_1582
                                                                                                                                                                        s_1583

                                                                                                                                                                    )

                                                                                                                                                                )

                                                                                                                                                            )

                                                                                                                                                      )
                                                                                                                                                        Vale.Def.Words_s.nat8
                                                                                                                                                        (
                                                                                                                                                          Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
                                                                                                                                                            (
                                                                                                                                                              Vale.Def.Words.Seq_s.seq_four_to_seq_BE
                                                                                                                                                                #Vale.Def.Words_s.nat32
                                                                                                                                                                raw_auth_quads

                                                                                                                                                            )

                                                                                                                                                        )
                                                                                                                                                        0
                                                                                                                                                        total_bytes

                                                                                                                                                    )
                                                                                                                                                    (
                                                                                                                                                      fun
                                                                                                                                                        _
                                                                                                                                                        ->
                                                                                                                                                        let
                                                                                                                                                        auth_input_bytes:(
                                                                                                                                                          FStar.Seq.Base.seq
                                                                                                                                                            Vale.Def.Words_s.nat8

                                                                                                                                                        )
                                                                                                                                                        =
                                                                                                                                                          FStar.Seq.Base.slice
                                                                                                                                                            #Vale.Def.Words_s.nat8
                                                                                                                                                            (
                                                                                                                                                              Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
                                                                                                                                                                (
                                                                                                                                                                  Vale.Def.Words.Seq_s.seq_four_to_seq_BE
                                                                                                                                                                    #Vale.Def.Words_s.nat32
                                                                                                                                                                    raw_auth_quads

                                                                                                                                                                )

                                                                                                                                                            )
                                                                                                                                                            0
                                                                                                                                                            total_bytes

                                                                                                                                                        in
                                                                                                                                                        let
                                                                                                                                                        padded_auth_bytes:(
                                                                                                                                                          FStar.Seq.Base.seq
                                                                                                                                                            Vale.Def.Types_s.nat8

                                                                                                                                                        )
                                                                                                                                                        =
                                                                                                                                                          Vale.AES.GCTR_BE_s.pad_to_128_bits
                                                                                                                                                            auth_input_bytes

                                                                                                                                                        in
                                                                                                                                                        let
                                                                                                                                                        auth_in
                                                                                                                                                        =
                                                                                                                                                          Vale.Def.Types_s.be_bytes_to_seq_quad32
                                                                                                                                                            padded_auth_bytes

                                                                                                                                                        in
                                                                                                                                                        let
                                                                                                                                                        plain_byte_seq
                                                                                                                                                        =
                                                                                                                                                          Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                            (
                                                                                                                                                              Vale.PPC64LE.Decls.s128
                                                                                                                                                                (
                                                                                                                                                                  va_get_mem_heaplet
                                                                                                                                                                    5
                                                                                                                                                                    va_old_s

                                                                                                                                                                )
                                                                                                                                                                inout_b

                                                                                                                                                            )

                                                                                                                                                        in
                                                                                                                                                        let
                                                                                                                                                        cipher_byte_seq
                                                                                                                                                        =
                                                                                                                                                          Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                            (
                                                                                                                                                              Vale.PPC64LE.Decls.s128
                                                                                                                                                                (
                                                                                                                                                                  va_get_mem_heaplet
                                                                                                                                                                    5
                                                                                                                                                                    va_s

                                                                                                                                                                )
                                                                                                                                                                inout_b

                                                                                                                                                            )

                                                                                                                                                        in
                                                                                                                                                        va_QEmpty
                                                                                                                                                          (
                                                                                                                                                            (
                                                                                                                                                              auth_in,
                                                                                                                                                              cipher_byte_seq,
                                                                                                                                                              plain_byte_seq,
                                                                                                                                                              y_inout
                                                                                                                                                            )
                                                                                                                                                          )

                                                                                                                                                    )

                                                                                                                                              )

                                                                                                                                          )

                                                                                                                                      )

                                                                                                                                  )

                                                                                                                            )

                                                                                                                      )

                                                                                                                  )
                                                                                                                  (
                                                                                                                    qblock
                                                                                                                      va_mods
                                                                                                                      (
                                                                                                                        fun
                                                                                                                          (
                                                                                                                            va_s:
                                                                                                                            va_state
                                                                                                                          )
                                                                                                                          ->
                                                                                                                          va_QEmpty
                                                                                                                            (
                                                                                                                              (
                                                                                                                                auth_in,
                                                                                                                                cipher_byte_seq,
                                                                                                                                plain_byte_seq,
                                                                                                                                y_inout
                                                                                                                              )
                                                                                                                            )

                                                                                                                      )

                                                                                                                  )

                                                                                                              )
                                                                                                              (
                                                                                                                fun
                                                                                                                  (
                                                                                                                    va_s:
                                                                                                                    va_state
                                                                                                                  )
                                                                                                                  va_g
                                                                                                                  ->
                                                                                                                  let
                                                                                                                  (
                                                                                                                    auth_in:
                                                                                                                    (
                                                                                                                      seq
                                                                                                                        quad32

                                                                                                                    )
                                                                                                                  ),
                                                                                                                  (
                                                                                                                    cipher_byte_seq:
                                                                                                                    (
                                                                                                                      seq
                                                                                                                        quad32

                                                                                                                    )
                                                                                                                  ),
                                                                                                                  (
                                                                                                                    plain_byte_seq:
                                                                                                                    (
                                                                                                                      seq
                                                                                                                        quad32

                                                                                                                    )
                                                                                                                  ),
                                                                                                                  (
                                                                                                                    y_inout:
                                                                                                                    quad32
                                                                                                                  )
                                                                                                                  =
                                                                                                                    va_g
                                                                                                                  in
                                                                                                                  va_QSeq
                                                                                                                    va_range1
                                                                                                                    "***** PRECONDITION NOT MET AT line 791 column 14 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                    (
                                                                                                                      va_quick_MemLoad64
                                                                                                                        (
                                                                                                                          va_op_heaplet_mem_heaplet
                                                                                                                            3

                                                                                                                        )
                                                                                                                        (
                                                                                                                          va_op_reg_opr_reg
                                                                                                                            7

                                                                                                                        )
                                                                                                                        (
                                                                                                                          va_op_reg_opr_reg
                                                                                                                            25

                                                                                                                        )
                                                                                                                        (
                                                                                                                          8
                                                                                                                          `op_Multiply`
                                                                                                                          8
                                                                                                                        )
                                                                                                                        Secret
                                                                                                                        gcm_struct_b
                                                                                                                        8

                                                                                                                    )
                                                                                                                    (
                                                                                                                      va_QBind
                                                                                                                        va_range1
                                                                                                                        "***** PRECONDITION NOT MET AT line 792 column 25 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                        (
                                                                                                                          va_quick_Gcm_make_length_quad
                                                                                                                            ()

                                                                                                                        )
                                                                                                                        (
                                                                                                                          fun
                                                                                                                            (
                                                                                                                              va_s:
                                                                                                                              va_state
                                                                                                                            )
                                                                                                                            _
                                                                                                                            ->
                                                                                                                            let
                                                                                                                            length_quad32:quad32
                                                                                                                            =
                                                                                                                              va_get_vec
                                                                                                                                9
                                                                                                                                va_s

                                                                                                                            in
                                                                                                                            va_QBind
                                                                                                                              va_range1
                                                                                                                              "***** PRECONDITION NOT MET AT line 795 column 19 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                              (
                                                                                                                                va_quick_Ghash_register
                                                                                                                                  hkeys_b
                                                                                                                                  h_BE
                                                                                                                                  y_inout

                                                                                                                              )
                                                                                                                              (
                                                                                                                                fun
                                                                                                                                  (
                                                                                                                                    va_s:
                                                                                                                                    va_state
                                                                                                                                  )
                                                                                                                                  _
                                                                                                                                  ->
                                                                                                                                  let
                                                                                                                                  y_final:quad32
                                                                                                                                  =
                                                                                                                                    va_get_vec
                                                                                                                                      1
                                                                                                                                      va_s

                                                                                                                                  in
                                                                                                                                  va_QSeq
                                                                                                                                    va_range1
                                                                                                                                    "***** PRECONDITION NOT MET AT line 798 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                    (
                                                                                                                                      va_quick_Vmr
                                                                                                                                        (
                                                                                                                                          va_op_vec_opr_vec
                                                                                                                                            7

                                                                                                                                        )
                                                                                                                                        (
                                                                                                                                          va_op_vec_opr_vec
                                                                                                                                            21

                                                                                                                                        )

                                                                                                                                    )
                                                                                                                                    (
                                                                                                                                      va_QBind
                                                                                                                                        va_range1
                                                                                                                                        "***** PRECONDITION NOT MET AT line 801 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                        (
                                                                                                                                          va_quick_Gctr_register
                                                                                                                                            alg
                                                                                                                                            key
                                                                                                                                            round_keys
                                                                                                                                            keys_b

                                                                                                                                        )
                                                                                                                                        (
                                                                                                                                          fun
                                                                                                                                            (
                                                                                                                                              va_s:
                                                                                                                                              va_state
                                                                                                                                            )
                                                                                                                                            _
                                                                                                                                            ->
                                                                                                                                            let
                                                                                                                                            va_arg104:Vale.Def.Types_s.quad32
                                                                                                                                            =
                                                                                                                                              va_get_vec
                                                                                                                                                1
                                                                                                                                                va_s

                                                                                                                                            in
                                                                                                                                            va_qPURE
                                                                                                                                              va_range1
                                                                                                                                              "***** PRECONDITION NOT MET AT line 803 column 40 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                              (
                                                                                                                                                fun
                                                                                                                                                  (
                                                                                                                                                    _:
                                                                                                                                                    unit
                                                                                                                                                  )
                                                                                                                                                  ->
                                                                                                                                                  Vale.Arch.Types.be_seq_quad32_to_bytes_of_singleton
                                                                                                                                                    va_arg104

                                                                                                                                              )
                                                                                                                                              (
                                                                                                                                                va_qAssertSquash
                                                                                                                                                  va_range1
                                                                                                                                                  "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 804 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                  (
                                                                                                                                                    (
                                                                                                                                                      fun
                                                                                                                                                        (
                                                                                                                                                          icb_661:
                                                                                                                                                          Vale.Def.Types_s.quad32
                                                                                                                                                        )
                                                                                                                                                        (
                                                                                                                                                          plain_662:
                                                                                                                                                          Vale.Def.Types_s.quad32
                                                                                                                                                        )
                                                                                                                                                        (
                                                                                                                                                          alg_663:
                                                                                                                                                          Vale.AES.AES_common_s.algorithm
                                                                                                                                                        )
                                                                                                                                                        (
                                                                                                                                                          key_664:
                                                                                                                                                          (
                                                                                                                                                            FStar.Seq.Base.seq
                                                                                                                                                              Vale.Def.Types_s.nat32

                                                                                                                                                          )
                                                                                                                                                        )
                                                                                                                                                        (
                                                                                                                                                          i_665:
                                                                                                                                                          Prims.int
                                                                                                                                                        )
                                                                                                                                                        ->
                                                                                                                                                        Vale.AES.AES_BE_s.is_aes_key_word
                                                                                                                                                          alg_663
                                                                                                                                                          key_664

                                                                                                                                                    )
                                                                                                                                                      j0
                                                                                                                                                      y_final
                                                                                                                                                      alg
                                                                                                                                                      key
                                                                                                                                                      0

                                                                                                                                                  )
                                                                                                                                                  (
                                                                                                                                                    fun
                                                                                                                                                      _
                                                                                                                                                      ->
                                                                                                                                                      va_qAssert
                                                                                                                                                        va_range1
                                                                                                                                                        "***** PRECONDITION NOT MET AT line 804 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                        (
                                                                                                                                                          va_get_vec
                                                                                                                                                            1
                                                                                                                                                            va_s
                                                                                                                                                           ==
                                                                                                                                                          Vale.AES.GCTR_BE_s.gctr_encrypt_block
                                                                                                                                                            j0
                                                                                                                                                            y_final
                                                                                                                                                            alg
                                                                                                                                                            key
                                                                                                                                                            0

                                                                                                                                                        )
                                                                                                                                                        (
                                                                                                                                                          let
                                                                                                                                                          plain128:(
                                                                                                                                                            FStar.Seq.Base.seq
                                                                                                                                                              Vale.Def.Types_s.quad32

                                                                                                                                                          )
                                                                                                                                                          =
                                                                                                                                                            Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                              (
                                                                                                                                                                Vale.PPC64LE.Decls.s128
                                                                                                                                                                  (
                                                                                                                                                                    va_get_mem_heaplet
                                                                                                                                                                      1
                                                                                                                                                                      va_old_s

                                                                                                                                                                  )
                                                                                                                                                                  in128_b

                                                                                                                                                              )

                                                                                                                                                          in
                                                                                                                                                          let
                                                                                                                                                          cipher128:(
                                                                                                                                                            FStar.Seq.Base.seq
                                                                                                                                                              Vale.Def.Types_s.quad32

                                                                                                                                                          )
                                                                                                                                                          =
                                                                                                                                                            Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                              (
                                                                                                                                                                Vale.PPC64LE.Decls.s128
                                                                                                                                                                  (
                                                                                                                                                                    va_get_mem_heaplet
                                                                                                                                                                      1
                                                                                                                                                                      va_s

                                                                                                                                                                  )
                                                                                                                                                                  in128_b

                                                                                                                                                              )

                                                                                                                                                          in
                                                                                                                                                          va_qAssert
                                                                                                                                                            va_range1
                                                                                                                                                            "***** PRECONDITION NOT MET AT line 809 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                            (
                                                                                                                                                              FStar.Seq.Base.length
                                                                                                                                                                #quad32
                                                                                                                                                                plain_byte_seq
                                                                                                                                                               ==
                                                                                                                                                              0 ==>
                                                                                                                                                              FStar.Seq.Base.equal
                                                                                                                                                                #Vale.Def.Types_s.quad32
                                                                                                                                                                (
                                                                                                                                                                  FStar.Seq.Base.append
                                                                                                                                                                    #Vale.Def.Types_s.quad32
                                                                                                                                                                    plain128
                                                                                                                                                                    plain_byte_seq

                                                                                                                                                                )
                                                                                                                                                                plain128

                                                                                                                                                            )
                                                                                                                                                            (
                                                                                                                                                              va_qAssert
                                                                                                                                                                va_range1
                                                                                                                                                                "***** PRECONDITION NOT MET AT line 810 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                                (
                                                                                                                                                                  FStar.Seq.Base.length
                                                                                                                                                                    #quad32
                                                                                                                                                                    cipher_byte_seq
                                                                                                                                                                   ==
                                                                                                                                                                  0 ==>
                                                                                                                                                                  FStar.Seq.Base.equal
                                                                                                                                                                    #Vale.Def.Types_s.quad32
                                                                                                                                                                    (
                                                                                                                                                                      FStar.Seq.Base.append
                                                                                                                                                                        #Vale.Def.Types_s.quad32
                                                                                                                                                                        cipher128
                                                                                                                                                                        cipher_byte_seq

                                                                                                                                                                    )
                                                                                                                                                                    cipher128

                                                                                                                                                                )
                                                                                                                                                                (
                                                                                                                                                                  let
                                                                                                                                                                  va_arg103:Vale.Def.Types_s.quad32
                                                                                                                                                                  =
                                                                                                                                                                    Vale.AES.GCTR_BE.inc32lite
                                                                                                                                                                      ctr_BE_2
                                                                                                                                                                      len128

                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg102:Vale.Def.Types_s.quad32
                                                                                                                                                                  =
                                                                                                                                                                    ctr_BE_2
                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg101:(
                                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                                      Vale.Def.Types_s.nat32

                                                                                                                                                                  )
                                                                                                                                                                  =
                                                                                                                                                                    key
                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg100:(
                                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                                      Vale.Def.Types_s.quad32

                                                                                                                                                                  )
                                                                                                                                                                  =
                                                                                                                                                                    cipher_byte_seq
                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg99:(
                                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                                      Vale.Def.Types_s.quad32

                                                                                                                                                                  )
                                                                                                                                                                  =
                                                                                                                                                                    plain_byte_seq
                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg98:(
                                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                                      Vale.Def.Types_s.quad32

                                                                                                                                                                  )
                                                                                                                                                                  =
                                                                                                                                                                    Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                                      (
                                                                                                                                                                        Vale.PPC64LE.Decls.s128
                                                                                                                                                                          (
                                                                                                                                                                            va_get_mem_heaplet
                                                                                                                                                                              1
                                                                                                                                                                              va_s

                                                                                                                                                                          )
                                                                                                                                                                          out128_b

                                                                                                                                                                      )

                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg97:(
                                                                                                                                                                    FStar.Seq.Base.seq
                                                                                                                                                                      Vale.Def.Types_s.quad32

                                                                                                                                                                  )
                                                                                                                                                                  =
                                                                                                                                                                    Vale.Arch.Types.reverse_bytes_quad32_seq
                                                                                                                                                                      (
                                                                                                                                                                        Vale.PPC64LE.Decls.s128
                                                                                                                                                                          (
                                                                                                                                                                            va_get_mem_heaplet
                                                                                                                                                                              1
                                                                                                                                                                              va_old_s

                                                                                                                                                                          )
                                                                                                                                                                          in128_b

                                                                                                                                                                      )

                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg96:Prims.nat
                                                                                                                                                                  =
                                                                                                                                                                    FStar.Seq.Base.length
                                                                                                                                                                      #quad32
                                                                                                                                                                      plain_byte_seq

                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg95:Prims.nat
                                                                                                                                                                  =
                                                                                                                                                                    len128
                                                                                                                                                                  in
                                                                                                                                                                  let
                                                                                                                                                                  va_arg94:Vale.AES.AES_common_s.algorithm
                                                                                                                                                                  =
                                                                                                                                                                    alg
                                                                                                                                                                  in
                                                                                                                                                                  va_qPURE
                                                                                                                                                                    va_range1
                                                                                                                                                                    "***** PRECONDITION NOT MET AT line 812 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                                    (
                                                                                                                                                                      fun
                                                                                                                                                                        (
                                                                                                                                                                          _:
                                                                                                                                                                          unit
                                                                                                                                                                        )
                                                                                                                                                                        ->
                                                                                                                                                                        Vale.AES.GCTR_BE.lemma_gctr_partial_append
                                                                                                                                                                          va_arg94
                                                                                                                                                                          va_arg95
                                                                                                                                                                          va_arg96
                                                                                                                                                                          va_arg97
                                                                                                                                                                          va_arg98
                                                                                                                                                                          va_arg99
                                                                                                                                                                          va_arg100
                                                                                                                                                                          va_arg101
                                                                                                                                                                          va_arg102
                                                                                                                                                                          va_arg103

                                                                                                                                                                    )
                                                                                                                                                                    (
                                                                                                                                                                      let
                                                                                                                                                                      va_arg93:Vale.Def.Types_s.quad32
                                                                                                                                                                      =
                                                                                                                                                                        length_quad32
                                                                                                                                                                      in
                                                                                                                                                                      let
                                                                                                                                                                      va_arg92:(
                                                                                                                                                                        FStar.Seq.Base.seq
                                                                                                                                                                          Vale.Def.Types_s.quad32

                                                                                                                                                                      )
                                                                                                                                                                      =
                                                                                                                                                                        auth_in
                                                                                                                                                                      in
                                                                                                                                                                      let
                                                                                                                                                                      va_arg91:Vale.Def.Types_s.quad32
                                                                                                                                                                      =
                                                                                                                                                                        y_final
                                                                                                                                                                      in
                                                                                                                                                                      let
                                                                                                                                                                      va_arg90:Vale.Def.Types_s.quad32
                                                                                                                                                                      =
                                                                                                                                                                        y_inout
                                                                                                                                                                      in
                                                                                                                                                                      let
                                                                                                                                                                      va_arg89:Vale.Def.Types_s.quad32
                                                                                                                                                                      =
                                                                                                                                                                        y_0
                                                                                                                                                                      in
                                                                                                                                                                      va_qPURE
                                                                                                                                                                        va_range1
                                                                                                                                                                        "***** PRECONDITION NOT MET AT line 820 column 23 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                                        (
                                                                                                                                                                          fun
                                                                                                                                                                            (
                                                                                                                                                                              _:
                                                                                                                                                                              unit
                                                                                                                                                                            )
                                                                                                                                                                            ->
                                                                                                                                                                            Vale.AES.GHash_BE.lemma_hash_append2
                                                                                                                                                                              h_BE
                                                                                                                                                                              va_arg89
                                                                                                                                                                              va_arg90
                                                                                                                                                                              va_arg91
                                                                                                                                                                              va_arg92
                                                                                                                                                                              va_arg93

                                                                                                                                                                        )
                                                                                                                                                                        (
                                                                                                                                                                          let
                                                                                                                                                                          auth_in
                                                                                                                                                                          =
                                                                                                                                                                            FStar.Seq.Base.append
                                                                                                                                                                              #quad32
                                                                                                                                                                              auth_in
                                                                                                                                                                              (
                                                                                                                                                                                FStar.Seq.Base.create
                                                                                                                                                                                  #quad32
                                                                                                                                                                                  1
                                                                                                                                                                                  length_quad32

                                                                                                                                                                              )

                                                                                                                                                                          in
                                                                                                                                                                          let
                                                                                                                                                                          va_arg88:(
                                                                                                                                                                            FStar.Seq.Base.seq
                                                                                                                                                                              Vale.Def.Types_s.quad32

                                                                                                                                                                          )
                                                                                                                                                                          =
                                                                                                                                                                            auth_in
                                                                                                                                                                          in
                                                                                                                                                                          va_qPURE
                                                                                                                                                                            va_range1
                                                                                                                                                                            "***** PRECONDITION NOT MET AT line 822 column 31 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
                                                                                                                                                                            (
                                                                                                                                                                              fun
                                                                                                                                                                                (
                                                                                                                                                                                  _:
                                                                                                                                                                                  unit
                                                                                                                                                                                )
                                                                                                                                                                                ->
                                                                                                                                                                                Vale.AES.GHash_BE.ghash_incremental_to_ghash
                                                                                                                                                                                  h_BE
                                                                                                                                                                                  va_arg88

                                                                                                                                                                            )
                                                                                                                                                                            (
                                                                                                                                                                              va_QEmpty
                                                                                                                                                                                (
                                                                                                                                                                                  ()
                                                                                                                                                                                )

                                                                                                                                                                            )

                                                                                                                                                                        )

                                                                                                                                                                    )

                                                                                                                                                                )

                                                                                                                                                            )

                                                                                                                                                        )

                                                                                                                                                  )

                                                                                                                                              )

                                                                                                                                        )

                                                                                                                                    )

                                                                                                                              )

                                                                                                                        )

                                                                                                                    )

                                                                                                              )

                                                                                                          )

                                                                                                    )
                                                                                                  ))
                                                                                      ))))))))))))))
                      ))))))
Vale.AES.PPC64LE.GCMencrypt.fst.checked
Vale.PPC64LE.State.fsti.checked Vale.PPC64LE.Stack_i.fsti.checked Vale.PPC64LE.QuickCodes.fsti.checked Vale.PPC64LE.QuickCode.fst.checked Vale.PPC64LE.Memory.fsti.checked Vale.PPC64LE.Machine_s.fst.checked Vale.PPC64LE.InsVector.fsti.checked Vale.PPC64LE.InsStack.fsti.checked Vale.PPC64LE.InsMem.fsti.checked Vale.PPC64LE.InsBasic.fsti.checked Vale.PPC64LE.Decls.fsti.checked Vale.Poly1305.Math.fsti.checked Vale.Math.Poly2.Bits_s.fsti.checked Vale.Lib.Meta.fsti.checked Vale.Lib.Basic.fsti.checked Vale.Def.Words_s.fsti.checked Vale.Def.Words.Seq_s.fsti.checked Vale.Def.Words.Four_s.fsti.checked Vale.Def.Types_s.fst.checked Vale.Def.Prop_s.fst.checked Vale.Def.Opaque_s.fsti.checked Vale.Arch.Types.fsti.checked Vale.Arch.HeapImpl.fsti.checked Vale.AES.Types_helpers.fsti.checked Vale.AES.PPC64LE.GHash.fsti.checked Vale.AES.PPC64LE.GF128_Mul.fsti.checked Vale.AES.PPC64LE.GCTR.fsti.checked Vale.AES.PPC64LE.AES.fsti.checked Vale.AES.OptPublic_BE.fsti.checked Vale.AES.GHash_BE_s.fst.checked Vale.AES.GHash_BE.fsti.checked Vale.AES.GF128_s.fsti.checked Vale.AES.GF128.fsti.checked Vale.AES.GCTR_BE_s.fst.checked Vale.AES.GCTR_BE.fsti.checked Vale.AES.GCM_helpers_BE.fsti.checked Vale.AES.GCM_BE_s.fst.checked Vale.AES.GCM_BE.fsti.checked Vale.AES.AES_common_s.fst.checked Vale.AES.AES_BE_s.fst.checked prims.fst.checked FStar.Seq.Base.fsti.checked FStar.Seq.fst.checked FStar.Pervasives.Native.fst.checked FStar.Pervasives.fsti.checked
Vale.AES.PPC64LE.GCMencrypt.fst
Vale.PPC64LE.QuickCode.va_mods_t Vale.AES.AES_common_s.algorithm Vale.PPC64LE.Memory.buffer128 FStar.Seq.Base.seq Vale.PPC64LE.Memory.nat32 Vale.PPC64LE.Memory.quad32 Vale.PPC64LE.Memory.buffer64 Vale.PPC64LE.QuickCodes.qblock Prims.unit Prims.Cons Vale.PPC64LE.Decls.va_code Vale.PPC64LE.InsMem.va_code_MemLoad64 Vale.PPC64LE.Decls.va_op_heaplet_mem_heaplet Vale.PPC64LE.Decls.va_op_reg_opr_reg Prims.op_Multiply Vale.Arch.HeapTypes_s.Secret Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_blocks_auth Vale.PPC64LE.InsVector.va_code_Load128_byte16_buffer Vale.PPC64LE.Decls.va_op_vec_opr_vec Vale.Arch.HeapTypes_s.Public Vale.PPC64LE.InsVector.va_code_Vmr Vale.AES.PPC64LE.GCMencrypt.va_code_Load_one_lsb Vale.PPC64LE.InsVector.va_code_Vadduwm Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_blocks128 Vale.PPC64LE.InsBasic.va_code_Sl64Imm Vale.PPC64LE.Machine_s.IfElse Vale.PPC64LE.Decls.ins Vale.PPC64LE.Decls.ocmp Vale.PPC64LE.QuickCodes.cmp_to_ocmp Vale.PPC64LE.QuickCodes.Cmp_gt Vale.PPC64LE.Decls.va_op_cmp_reg Vale.PPC64LE.QuickCodes.block Vale.PPC64LE.InsBasic.va_code_LoadImm64 Vale.PPC64LE.InsBasic.va_code_And Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_extra_bytes Vale.PPC64LE.Machine_s.Block Prims.Nil Vale.PPC64LE.Machine_s.precode Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_make_length_quad Vale.AES.PPC64LE.GHash.va_code_Ghash_register Vale.AES.PPC64LE.GCTR.va_code_Gctr_register Vale.PPC64LE.Decls.va_state Vale.PPC64LE.QuickCodes.va_QSeq Vale.PPC64LE.QuickCodes.va_range1 Vale.PPC64LE.InsMem.va_quick_MemLoad64 Vale.PPC64LE.QuickCodes.va_QBind Vale.AES.PPC64LE.GCMencrypt.va_quick_Gcm_blocks_auth Vale.PPC64LE.InsVector.va_quick_Load128_byte16_buffer Vale.PPC64LE.InsVector.va_quick_Vmr Vale.AES.PPC64LE.GCMencrypt.va_quick_Load_one_lsb Vale.PPC64LE.InsVector.va_quick_Vadduwm Vale.AES.PPC64LE.GCMencrypt.va_quick_Gcm_blocks128 Vale.PPC64LE.QuickCodes.va_qPURE Prims.pure_post Prims.l_and Prims.b2t Prims.op_Equality Vale.Def.Types_s.quad32 Vale.AES.GHash_BE.ghash_incremental0 Prims.l_Forall Prims.l_imp FStar.Seq.Base.op_At_Bar Vale.AES.GHash_BE.lemma_ghash_incremental0_append Prims.l_True Prims.eq2 Prims.int Vale.Def.Types_s.ishl Prims.op_Modulus Prims.pow2 Vale.AES.Types_helpers.lemma_ishl_64 Vale.PPC64LE.InsBasic.va_quick_Sl64Imm Vale.AES.AES_BE_s.is_aes_key_word Vale.AES.GCTR_BE.gctr_partial Vale.AES.GCTR_BE.gctr_partial_opaque_init FStar.Pervasives.Native.tuple4 Vale.PPC64LE.Machine_s.quad32 Vale.PPC64LE.QuickCodes.va_qIf Vale.Def.Words_s.nat64 Vale.Def.Types_s.ishr Prims.op_Division Vale.Def.Types_s.iand Prims.op_LessThan Vale.Poly1305.Math.lemma_poly_bits64 Vale.PPC64LE.InsBasic.va_quick_LoadImm64 Vale.PPC64LE.InsBasic.va_quick_And Vale.AES.PPC64LE.GCMencrypt.va_quick_Gcm_extra_bytes Vale.PPC64LE.QuickCodes.va_qAssertSquash Prims.op_AmpAmp Prims.op_LessThanOrEqual FStar.Seq.Base.length Vale.Def.Words_s.nat8 Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE Vale.Def.Words.Seq_s.seq_four_to_seq_BE Vale.Def.Words_s.nat32 Prims.nat Prims.squash Vale.PPC64LE.QuickCodes.va_QEmpty FStar.Pervasives.Native.Mktuple4 Vale.Arch.Types.reverse_bytes_quad32_seq Vale.PPC64LE.Decls.s128 Vale.PPC64LE.Decls.va_get_mem_heaplet Vale.Def.Types_s.be_bytes_to_seq_quad32 Vale.AES.GCTR_BE_s.pad_to_128_bits FStar.Seq.Base.slice Vale.PPC64LE.QuickCodes.quickCodes FStar.Seq.Base.append Vale.PPC64LE.Decls.va_get_vec Vale.AES.PPC64LE.GCMencrypt.va_quick_Gcm_make_length_quad Vale.AES.PPC64LE.GHash.va_quick_Ghash_register Vale.AES.PPC64LE.GCTR.va_quick_Gctr_register Vale.Arch.Types.be_quad32_to_bytes FStar.Seq.Base.create Vale.Def.Words_s.four Vale.Arch.Types.be_seq_quad32_to_bytes_of_singleton Vale.PPC64LE.QuickCodes.va_qAssert Vale.AES.GCTR_BE_s.gctr_encrypt_block FStar.Seq.Base.equal Vale.AES.GCTR_BE_s.inc32 Prims.op_Addition Vale.AES.GCTR_BE.lemma_gctr_partial_append Vale.AES.GHash_BE.ghash_incremental Vale.AES.GHash_BE.lemma_hash_append2 Prims.op_GreaterThan Vale.Def.Words_s.Mkfour Vale.AES.GHash_BE_s.ghash_BE Vale.AES.GHash_BE.ghash_incremental_to_ghash Vale.AES.GCTR_BE.inc32lite Vale.PPC64LE.Decls.va_int_at_least Vale.AES.GCTR_BE.empty_seq_quad32 Vale.PPC64LE.Decls.va_get_reg Vale.Def.Types_s.reverse_bytes_quad32 Vale.PPC64LE.Decls.buffer128_read Vale.Def.Types_s.nat32 Vale.PPC64LE.Decls.buffer64_read Vale.PPC64LE.Machine_s.state Vale.PPC64LE.QuickCode.va_quickCode Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_blocks
module Vale.AES.PPC64LE.GCMencrypt
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_BE_s
open Vale.AES.GCTR_BE_s
open Vale.AES.GCTR_BE
open Vale.AES.GCM_BE
open Vale.AES.GHash_BE_s
open Vale.AES.GHash_BE
open Vale.AES.GCM_BE_s
open Vale.AES.PPC64LE.AES
open Vale.AES.GF128_s
open Vale.AES.GF128
open Vale.Poly1305.Math
open Vale.AES.GCM_helpers_BE
open Vale.AES.PPC64LE.GCTR
open Vale.PPC64LE.Machine_s
open Vale.PPC64LE.Memory
open Vale.PPC64LE.Stack_i
open Vale.PPC64LE.State
open Vale.PPC64LE.Decls
open Vale.PPC64LE.InsBasic
open Vale.PPC64LE.InsMem
open Vale.PPC64LE.InsVector
open Vale.PPC64LE.InsStack
open Vale.PPC64LE.QuickCode
open Vale.PPC64LE.QuickCodes
open Vale.AES.PPC64LE.GF128_Mul
open Vale.Math.Poly2.Bits_s
open Vale.AES.PPC64LE.GHash
open Vale.Lib.Meta
open Vale.AES.OptPublic_BE
open Vale.Lib.Basic
#reset-options "--z3rlimit 2000 --fuel 10 --ifuel 10 --max_fuel 100 --max_ifuel 100"
//-- Load_one_lsb

[@ "opaque_to_smt"]
let va_code_Load_one_lsb dst =
  (va_Block (va_CCons (va_code_Vspltisw dst 1) (va_CCons (va_code_Vspltisw (va_op_vec_opr_vec 4) 0)
    (va_CCons (va_code_Vsldoi dst (va_op_vec_opr_vec 4) dst 4) (va_CNil ())))))

[@ "opaque_to_smt"]
let va_codegen_success_Load_one_lsb dst =
  (va_pbool_and (va_codegen_success_Vspltisw dst 1) (va_pbool_and (va_codegen_success_Vspltisw
    (va_op_vec_opr_vec 4) 0) (va_pbool_and (va_codegen_success_Vsldoi dst (va_op_vec_opr_vec 4) dst
    4) (va_ttrue ()))))

[@"opaque_to_smt"]
let va_lemma_Load_one_lsb va_b0 va_s0 dst =
  va_reveal_opaque (`%va_code_Load_one_lsb) (va_code_Load_one_lsb dst);
  let (va_old_s:va_state) = va_s0 in
  let (va_b1:va_codes) = va_get_block va_b0 in
  let (va_s2, va_fc2) = va_lemma_Vspltisw (va_hd va_b1) va_s0 dst 1 in
  let va_b2 = va_tl va_b1 in
  let (va_s3, va_fc3) = va_lemma_Vspltisw (va_hd va_b2) va_s2 (va_op_vec_opr_vec 4) 0 in
  let va_b3 = va_tl va_b2 in
  let (va_s4, va_fc4) = va_lemma_Vsldoi (va_hd va_b3) va_s3 dst (va_op_vec_opr_vec 4) dst 4 in
  let va_b4 = va_tl va_b3 in
  let (va_sM, va_f4) = va_lemma_empty_total va_s4 va_b4 in
  let va_f3 = va_lemma_merge_total va_b3 va_s3 va_fc4 va_s4 va_f4 va_sM in
  let va_f2 = va_lemma_merge_total va_b2 va_s2 va_fc3 va_s3 va_f3 va_sM in
  let va_fM = va_lemma_merge_total va_b1 va_s0 va_fc2 va_s2 va_f2 va_sM in
  (va_sM, va_fM)


[@"opaque_to_smt"]
let va_wpProof_Load_one_lsb dst va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Load_one_lsb (va_code_Load_one_lsb dst) va_s0 dst in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_vec 4 va_sM (va_update_ok va_sM (va_update_operand_vec_opr
    dst va_sM va_s0))));
  va_lemma_norm_mods ([va_Mod_vec 4; va_mod_vec_opr dst]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

//--
//-- Gcm_blocks128

val va_code_Gcm_blocks128 : alg:algorithm -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_blocks128 alg =
  (va_Block (va_CCons (va_code_Vmr (va_op_vec_opr_vec 20) (va_op_vec_opr_vec 1)) (va_CCons
    (va_code_Gctr_blocks128 alg) (va_CCons (va_code_Vmr (va_op_vec_opr_vec 15) (va_op_vec_opr_vec
    7)) (va_CCons (va_code_Vmr (va_op_vec_opr_vec 1) (va_op_vec_opr_vec 20)) (va_CCons
    (va_code_Ghash_buffer ()) (va_CCons (va_code_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 15))
    (va_CNil ()))))))))

val va_codegen_success_Gcm_blocks128 : alg:algorithm -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_blocks128 alg =
  (va_pbool_and (va_codegen_success_Vmr (va_op_vec_opr_vec 20) (va_op_vec_opr_vec 1)) (va_pbool_and
    (va_codegen_success_Gctr_blocks128 alg) (va_pbool_and (va_codegen_success_Vmr
    (va_op_vec_opr_vec 15) (va_op_vec_opr_vec 7)) (va_pbool_and (va_codegen_success_Vmr
    (va_op_vec_opr_vec 1) (va_op_vec_opr_vec 20)) (va_pbool_and (va_codegen_success_Ghash_buffer
    ()) (va_pbool_and (va_codegen_success_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 15))
    (va_ttrue ())))))))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_blocks128 (va_mods:va_mods_t) (alg:algorithm) (in_b:buffer128) (out_b:buffer128)
  (key:(seq nat32)) (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (h_BE:quad32)
  : (va_quickCode unit (va_code_Gcm_blocks128 alg)) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 167 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 20) (va_op_vec_opr_vec 1)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 168 column 19 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gctr_blocks128 alg in_b out_b key round_keys keys_b) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 169 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 15) (va_op_vec_opr_vec 7)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 170 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 1) (va_op_vec_opr_vec 20)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 171 column 17 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_buffer hkeys_b out_b h_BE (va_get_vec 1 va_old_s)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 172 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 15)) (va_QEmpty (())))))))))


val va_lemma_Gcm_blocks128 : va_b0:va_code -> va_s0:va_state -> alg:algorithm -> in_b:buffer128 ->
  out_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 ->
  hkeys_b:buffer128 -> h_BE:quad32
  -> Ghost (va_state & va_fuel)
  (requires (va_require_total va_b0 (va_code_Gcm_blocks128 alg) va_s0 /\ va_get_ok va_s0 /\
    ((Vale.PPC64LE.Decls.buffers_disjoint128 in_b out_b \/ in_b == out_b) /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1 va_s0) (va_get_reg 3 va_s0) in_b
    (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validDstAddrs128
    (va_get_mem_heaplet 1 va_s0) (va_get_reg 7 va_s0) out_b (va_get_reg 6 va_s0) (va_get_mem_layout
    va_s0) Secret /\ va_get_reg 3 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\
    va_get_reg 7 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\ l_and
    (Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b ==
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 out_b)
    (Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b < pow2_32) /\ va_get_reg 6
    va_s0 == Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b /\ va_get_reg 6
    va_s0 < pow2_32 /\ aes_reqs alg key round_keys keys_b (va_get_reg 4 va_s0) (va_get_mem_heaplet
    0 va_s0) (va_get_mem_layout va_s0) /\ Vale.AES.GHash_BE.hkeys_reqs_priv
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0)
    hkeys_b)) h_BE /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg
    5 va_s0) hkeys_b 3 (va_get_mem_layout va_s0) Secret)))
  (ensures (fun (va_sM, va_fM) -> va_ensure_total va_b0 va_s0 va_sM va_fM /\ va_get_ok va_sM /\
    (Vale.PPC64LE.Decls.modifies_buffer128 out_b (va_get_mem_heaplet 1 va_s0) (va_get_mem_heaplet 1
    va_sM) /\ Vale.AES.GCTR_BE.gctr_partial alg (va_get_reg 6 va_s0)
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0)
    in_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_sM) out_b)) key (va_get_vec 7 va_s0) /\ va_get_vec 7 va_sM == Vale.AES.GCTR_BE.inc32lite
    (va_get_vec 7 va_s0) (va_get_reg 6 va_s0) /\ (va_get_reg 6 va_s0 == 0 ==> l_and (va_get_vec 1
    va_sM == va_get_vec 1 va_s0) (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b ==
    Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0) out_b)) /\ (va_get_reg 6 va_s0 > 0 ==>
    l_and (va_get_reg 6 va_s0 <= FStar.Seq.Base.length #Vale.PPC64LE.Machine_s.quad32
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) ==> FStar.Seq.Base.length
    #Vale.PPC64LE.Machine_s.quad32 (FStar.Seq.Base.slice #Vale.PPC64LE.Machine_s.quad32
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) 0 (va_get_reg 6 va_s0)) > 0)
    (va_get_vec 1 va_sM == Vale.AES.GHash_BE.ghash_incremental h_BE (va_get_vec 1 va_s0)
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    out_b))))) /\ va_state_eq va_sM (va_update_mem_heaplet 1 va_sM (va_update_cr0 va_sM
    (va_update_vec 20 va_sM (va_update_vec 19 va_sM (va_update_vec 18 va_sM (va_update_vec 17 va_sM
    (va_update_vec 16 va_sM (va_update_vec 15 va_sM (va_update_vec 14 va_sM (va_update_vec 13 va_sM
    (va_update_vec 12 va_sM (va_update_vec 11 va_sM (va_update_vec 10 va_sM (va_update_vec 9 va_sM
    (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5 va_sM
    (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1 va_sM
    (va_update_vec 0 va_sM (va_update_reg 31 va_sM (va_update_reg 30 va_sM (va_update_reg 29 va_sM
    (va_update_reg 28 va_sM (va_update_reg 27 va_sM (va_update_reg 26 va_sM (va_update_reg 10 va_sM
    (va_update_reg 9 va_sM (va_update_reg 8 va_sM (va_update_reg 6 va_sM (va_update_reg 7 va_sM
    (va_update_reg 3 va_sM (va_update_ok va_sM (va_update_mem va_sM
    va_s0)))))))))))))))))))))))))))))))))))))))
[@"opaque_to_smt"]
let va_lemma_Gcm_blocks128 va_b0 va_s0 alg in_b out_b key round_keys keys_b hkeys_b h_BE =
  let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 20; va_Mod_vec 19;
    va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13;
    va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 31; va_Mod_reg 30; va_Mod_reg 29; va_Mod_reg 28; va_Mod_reg 27; va_Mod_reg 26;
    va_Mod_reg 10; va_Mod_reg 9; va_Mod_reg 8; va_Mod_reg 6; va_Mod_reg 7; va_Mod_reg 3; va_Mod_ok;
    va_Mod_mem] in
  let va_qc = va_qcode_Gcm_blocks128 va_mods alg in_b out_b key round_keys keys_b hkeys_b h_BE in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Gcm_blocks128 alg) va_qc va_s0 (fun
    va_s0 va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 114 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ (label va_range1
    "***** POSTCONDITION NOT MET AT line 156 column 53 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.PPC64LE.Decls.modifies_buffer128 out_b (va_get_mem_heaplet 1 va_s0) (va_get_mem_heaplet 1
    va_sM)) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 159 column 147 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.AES.GCTR_BE.gctr_partial alg (va_get_reg 6 va_s0)
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0)
    in_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_sM) out_b)) key (va_get_vec 7 va_s0)) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 160 column 45 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 7 va_sM == Vale.AES.GCTR_BE.inc32lite (va_get_vec 7 va_s0) (va_get_reg 6 va_s0)) /\
    label va_range1
    "***** POSTCONDITION NOT MET AT line 163 column 93 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 6 va_s0 == 0 ==> l_and (va_get_vec 1 va_sM == va_get_vec 1 va_s0)
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b == Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 1 va_s0) out_b)) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 165 column 109 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 6 va_s0 > 0 ==> l_and (va_get_reg 6 va_s0 <= FStar.Seq.Base.length
    #Vale.PPC64LE.Machine_s.quad32 (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) ==>
    FStar.Seq.Base.length #Vale.PPC64LE.Machine_s.quad32 (FStar.Seq.Base.slice
    #Vale.PPC64LE.Machine_s.quad32 (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) 0
    (va_get_reg 6 va_s0)) > 0) (va_get_vec 1 va_sM == Vale.AES.GHash_BE.ghash_incremental h_BE
    (va_get_vec 1 va_s0) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 1 va_sM) out_b)))))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 20; va_Mod_vec 19; va_Mod_vec
    18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12;
    va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6;
    va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg
    31; va_Mod_reg 30; va_Mod_reg 29; va_Mod_reg 28; va_Mod_reg 27; va_Mod_reg 26; va_Mod_reg 10;
    va_Mod_reg 9; va_Mod_reg 8; va_Mod_reg 6; va_Mod_reg 7; va_Mod_reg 3; va_Mod_ok; va_Mod_mem])
    va_sM va_s0;
  (va_sM, va_fM)

[@ va_qattr]
let va_wp_Gcm_blocks128 (alg:algorithm) (in_b:buffer128) (out_b:buffer128) (key:(seq nat32))
  (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (h_BE:quad32) (va_s0:va_state)
  (va_k:(va_state -> unit -> Type0)) : Type0 =
  (va_get_ok va_s0 /\ ((Vale.PPC64LE.Decls.buffers_disjoint128 in_b out_b \/ in_b == out_b) /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1 va_s0) (va_get_reg 3 va_s0) in_b
    (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validDstAddrs128
    (va_get_mem_heaplet 1 va_s0) (va_get_reg 7 va_s0) out_b (va_get_reg 6 va_s0) (va_get_mem_layout
    va_s0) Secret /\ va_get_reg 3 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\
    va_get_reg 7 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\ l_and
    (Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b ==
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 out_b)
    (Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b < pow2_32) /\ va_get_reg 6
    va_s0 == Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 in_b /\ va_get_reg 6
    va_s0 < pow2_32 /\ aes_reqs alg key round_keys keys_b (va_get_reg 4 va_s0) (va_get_mem_heaplet
    0 va_s0) (va_get_mem_layout va_s0) /\ Vale.AES.GHash_BE.hkeys_reqs_priv
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0)
    hkeys_b)) h_BE /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg
    5 va_s0) hkeys_b 3 (va_get_mem_layout va_s0) Secret) /\ (forall (va_x_mem:vale_heap)
    (va_x_r3:nat64) (va_x_r7:nat64) (va_x_r6:nat64) (va_x_r8:nat64) (va_x_r9:nat64)
    (va_x_r10:nat64) (va_x_r26:nat64) (va_x_r27:nat64) (va_x_r28:nat64) (va_x_r29:nat64)
    (va_x_r30:nat64) (va_x_r31:nat64) (va_x_v0:quad32) (va_x_v1:quad32) (va_x_v2:quad32)
    (va_x_v3:quad32) (va_x_v4:quad32) (va_x_v5:quad32) (va_x_v6:quad32) (va_x_v7:quad32)
    (va_x_v8:quad32) (va_x_v9:quad32) (va_x_v10:quad32) (va_x_v11:quad32) (va_x_v12:quad32)
    (va_x_v13:quad32) (va_x_v14:quad32) (va_x_v15:quad32) (va_x_v16:quad32) (va_x_v17:quad32)
    (va_x_v18:quad32) (va_x_v19:quad32) (va_x_v20:quad32) (va_x_cr0:cr0_t) (va_x_heap1:vale_heap) .
    let va_sM = va_upd_mem_heaplet 1 va_x_heap1 (va_upd_cr0 va_x_cr0 (va_upd_vec 20 va_x_v20
    (va_upd_vec 19 va_x_v19 (va_upd_vec 18 va_x_v18 (va_upd_vec 17 va_x_v17 (va_upd_vec 16 va_x_v16
    (va_upd_vec 15 va_x_v15 (va_upd_vec 14 va_x_v14 (va_upd_vec 13 va_x_v13 (va_upd_vec 12 va_x_v12
    (va_upd_vec 11 va_x_v11 (va_upd_vec 10 va_x_v10 (va_upd_vec 9 va_x_v9 (va_upd_vec 8 va_x_v8
    (va_upd_vec 7 va_x_v7 (va_upd_vec 6 va_x_v6 (va_upd_vec 5 va_x_v5 (va_upd_vec 4 va_x_v4
    (va_upd_vec 3 va_x_v3 (va_upd_vec 2 va_x_v2 (va_upd_vec 1 va_x_v1 (va_upd_vec 0 va_x_v0
    (va_upd_reg 31 va_x_r31 (va_upd_reg 30 va_x_r30 (va_upd_reg 29 va_x_r29 (va_upd_reg 28 va_x_r28
    (va_upd_reg 27 va_x_r27 (va_upd_reg 26 va_x_r26 (va_upd_reg 10 va_x_r10 (va_upd_reg 9 va_x_r9
    (va_upd_reg 8 va_x_r8 (va_upd_reg 6 va_x_r6 (va_upd_reg 7 va_x_r7 (va_upd_reg 3 va_x_r3
    (va_upd_mem va_x_mem va_s0))))))))))))))))))))))))))))))))))) in va_get_ok va_sM /\
    (Vale.PPC64LE.Decls.modifies_buffer128 out_b (va_get_mem_heaplet 1 va_s0) (va_get_mem_heaplet 1
    va_sM) /\ Vale.AES.GCTR_BE.gctr_partial alg (va_get_reg 6 va_s0)
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0)
    in_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_sM) out_b)) key (va_get_vec 7 va_s0) /\ va_get_vec 7 va_sM == Vale.AES.GCTR_BE.inc32lite
    (va_get_vec 7 va_s0) (va_get_reg 6 va_s0) /\ (va_get_reg 6 va_s0 == 0 ==> l_and (va_get_vec 1
    va_sM == va_get_vec 1 va_s0) (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b ==
    Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0) out_b)) /\ (va_get_reg 6 va_s0 > 0 ==>
    l_and (va_get_reg 6 va_s0 <= FStar.Seq.Base.length #Vale.PPC64LE.Machine_s.quad32
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) ==> FStar.Seq.Base.length
    #Vale.PPC64LE.Machine_s.quad32 (FStar.Seq.Base.slice #Vale.PPC64LE.Machine_s.quad32
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM) out_b) 0 (va_get_reg 6 va_s0)) > 0)
    (va_get_vec 1 va_sM == Vale.AES.GHash_BE.ghash_incremental h_BE (va_get_vec 1 va_s0)
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    out_b))))) ==> va_k va_sM (())))


val va_wpProof_Gcm_blocks128 : alg:algorithm -> in_b:buffer128 -> out_b:buffer128 -> key:(seq
  nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 -> hkeys_b:buffer128 -> h_BE:quad32 ->
  va_s0:va_state -> va_k:(va_state -> unit -> Type0)
  -> Ghost (va_state & va_fuel & unit)
  (requires (va_t_require va_s0 /\ va_wp_Gcm_blocks128 alg in_b out_b key round_keys keys_b hkeys_b
    h_BE va_s0 va_k))
  (ensures (fun (va_sM, va_f0, va_g) -> va_t_ensure (va_code_Gcm_blocks128 alg)
    ([va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 20; va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17;
    va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11;
    va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec
    4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 31; va_Mod_reg 30;
    va_Mod_reg 29; va_Mod_reg 28; va_Mod_reg 27; va_Mod_reg 26; va_Mod_reg 10; va_Mod_reg 9;
    va_Mod_reg 8; va_Mod_reg 6; va_Mod_reg 7; va_Mod_reg 3; va_Mod_mem]) va_s0 va_k ((va_sM, va_f0,
    va_g))))
[@"opaque_to_smt"]
let va_wpProof_Gcm_blocks128 alg in_b out_b key round_keys keys_b hkeys_b h_BE va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Gcm_blocks128 (va_code_Gcm_blocks128 alg) va_s0 alg in_b out_b key
    round_keys keys_b hkeys_b h_BE in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_mem_heaplet 1 va_sM (va_update_cr0 va_sM (va_update_vec 20
    va_sM (va_update_vec 19 va_sM (va_update_vec 18 va_sM (va_update_vec 17 va_sM (va_update_vec 16
    va_sM (va_update_vec 15 va_sM (va_update_vec 14 va_sM (va_update_vec 13 va_sM (va_update_vec 12
    va_sM (va_update_vec 11 va_sM (va_update_vec 10 va_sM (va_update_vec 9 va_sM (va_update_vec 8
    va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5 va_sM (va_update_vec 4
    va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1 va_sM (va_update_vec 0
    va_sM (va_update_reg 31 va_sM (va_update_reg 30 va_sM (va_update_reg 29 va_sM (va_update_reg 28
    va_sM (va_update_reg 27 va_sM (va_update_reg 26 va_sM (va_update_reg 10 va_sM (va_update_reg 9
    va_sM (va_update_reg 8 va_sM (va_update_reg 6 va_sM (va_update_reg 7 va_sM (va_update_reg 3
    va_sM (va_update_ok va_sM (va_update_mem va_sM va_s0))))))))))))))))))))))))))))))))))))));
  va_lemma_norm_mods ([va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 20; va_Mod_vec 19; va_Mod_vec
    18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12;
    va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6;
    va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg
    31; va_Mod_reg 30; va_Mod_reg 29; va_Mod_reg 28; va_Mod_reg 27; va_Mod_reg 26; va_Mod_reg 10;
    va_Mod_reg 9; va_Mod_reg 8; va_Mod_reg 6; va_Mod_reg 7; va_Mod_reg 3; va_Mod_mem]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

[@ "opaque_to_smt" va_qattr]
let va_quick_Gcm_blocks128 (alg:algorithm) (in_b:buffer128) (out_b:buffer128) (key:(seq nat32))
  (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (h_BE:quad32) : (va_quickCode
  unit (va_code_Gcm_blocks128 alg)) =
  (va_QProc (va_code_Gcm_blocks128 alg) ([va_Mod_mem_heaplet 1; va_Mod_cr0; va_Mod_vec 20;
    va_Mod_vec 19; va_Mod_vec 18; va_Mod_vec 17; va_Mod_vec 16; va_Mod_vec 15; va_Mod_vec 14;
    va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8;
    va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec
    1; va_Mod_vec 0; va_Mod_reg 31; va_Mod_reg 30; va_Mod_reg 29; va_Mod_reg 28; va_Mod_reg 27;
    va_Mod_reg 26; va_Mod_reg 10; va_Mod_reg 9; va_Mod_reg 8; va_Mod_reg 6; va_Mod_reg 7;
    va_Mod_reg 3; va_Mod_mem]) (va_wp_Gcm_blocks128 alg in_b out_b key round_keys keys_b hkeys_b
    h_BE) (va_wpProof_Gcm_blocks128 alg in_b out_b key round_keys keys_b hkeys_b h_BE))
//--
//-- Gcm_auth_bytes

val va_code_Gcm_auth_bytes : va_dummy:unit -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_auth_bytes () =
  (va_Block (va_CCons (va_code_Vspltisw (va_op_vec_opr_vec 1) 0) (va_CCons (va_code_Ghash_buffer
    ()) (va_CNil ()))))

val va_codegen_success_Gcm_auth_bytes : va_dummy:unit -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_auth_bytes () =
  (va_pbool_and (va_codegen_success_Vspltisw (va_op_vec_opr_vec 1) 0) (va_pbool_and
    (va_codegen_success_Ghash_buffer ()) (va_ttrue ())))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_auth_bytes (va_mods:va_mods_t) (auth_b:buffer128) (hkeys_b:buffer128)
  (h_BE:quad32) : (va_quickCode (quad32 & quad32) (va_code_Gcm_auth_bytes ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 206 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vspltisw (va_op_vec_opr_vec 1) 0) (fun (va_s:va_state) _ -> let (y_0:quad32) =
    Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0 0 0 in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 208 column 17 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_buffer hkeys_b auth_b h_BE y_0) (fun (va_s:va_state) _ -> let (y_auth:quad32) =
    va_get_vec 1 va_s in va_QEmpty ((y_0, y_auth))))))


val va_lemma_Gcm_auth_bytes : va_b0:va_code -> va_s0:va_state -> auth_b:buffer128 ->
  hkeys_b:buffer128 -> h_BE:quad32
  -> Ghost (va_state & va_fuel & quad32 & quad32)
  (requires (va_require_total va_b0 (va_code_Gcm_auth_bytes ()) va_s0 /\ va_get_ok va_s0 /\
    (Vale.AES.GHash_BE.hkeys_reqs_priv (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0) hkeys_b)) h_BE /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg 5 va_s0) hkeys_b 3
    (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1
    va_s0) (va_get_reg 7 va_s0) auth_b (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 auth_b == va_get_reg 6 va_s0 /\
    va_get_reg 7 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64)))
  (ensures (fun (va_sM, va_fM, y_0, y_auth) -> va_ensure_total va_b0 va_s0 va_sM va_fM /\ va_get_ok
    va_sM /\ (y_0 == Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0 0 0 /\ (let h_BE =
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_s0)) in y_auth == Vale.AES.GHash_BE.ghash_incremental0 h_BE y_0
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    auth_b)) /\ va_get_vec 1 va_sM == y_auth)) /\ va_state_eq va_sM (va_update_cr0 va_sM
    (va_update_vec 14 va_sM (va_update_vec 13 va_sM (va_update_vec 12 va_sM (va_update_vec 11 va_sM
    (va_update_vec 10 va_sM (va_update_vec 9 va_sM (va_update_vec 8 va_sM (va_update_vec 7 va_sM
    (va_update_vec 6 va_sM (va_update_vec 5 va_sM (va_update_vec 4 va_sM (va_update_vec 3 va_sM
    (va_update_vec 2 va_sM (va_update_vec 1 va_sM (va_update_vec 0 va_sM (va_update_reg 10 va_sM
    (va_update_reg 6 va_sM (va_update_reg 7 va_sM (va_update_ok va_sM va_s0))))))))))))))))))))))
[@"opaque_to_smt"]
let va_lemma_Gcm_auth_bytes va_b0 va_s0 auth_b hkeys_b h_BE =
  let (va_mods:va_mods_t) = [va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec
    11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5;
    va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg
    6; va_Mod_reg 7; va_Mod_ok] in
  let va_qc = va_qcode_Gcm_auth_bytes va_mods auth_b hkeys_b h_BE in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Gcm_auth_bytes ()) va_qc va_s0 (fun
    va_s0 va_sM va_g -> let (y_0, y_auth) = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 175 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ (label va_range1
    "***** POSTCONDITION NOT MET AT line 200 column 34 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (y_0 == Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0 0 0) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 201 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let h_BE = Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_s0)) in label va_range1
    "***** POSTCONDITION NOT MET AT line 202 column 95 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (y_auth == Vale.AES.GHash_BE.ghash_incremental0 h_BE y_0
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    auth_b))) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 203 column 23 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 1 va_sM == y_auth)))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11;
    va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec
    4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 6;
    va_Mod_reg 7; va_Mod_ok]) va_sM va_s0;
  let (y_0, y_auth) = va_g in
  (va_sM, va_fM, y_0, y_auth)

[@ va_qattr]
let va_wp_Gcm_auth_bytes (auth_b:buffer128) (hkeys_b:buffer128) (h_BE:quad32) (va_s0:va_state)
  (va_k:(va_state -> (quad32 & quad32) -> Type0)) : Type0 =
  (va_get_ok va_s0 /\ (Vale.AES.GHash_BE.hkeys_reqs_priv (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0) hkeys_b)) h_BE /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg 5 va_s0) hkeys_b 3
    (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1
    va_s0) (va_get_reg 7 va_s0) auth_b (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 auth_b == va_get_reg 6 va_s0 /\
    va_get_reg 7 va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64) /\ (forall (va_x_r7:nat64)
    (va_x_r6:nat64) (va_x_r10:nat64) (va_x_v0:quad32) (va_x_v1:quad32) (va_x_v2:quad32)
    (va_x_v3:quad32) (va_x_v4:quad32) (va_x_v5:quad32) (va_x_v6:quad32) (va_x_v7:quad32)
    (va_x_v8:quad32) (va_x_v9:quad32) (va_x_v10:quad32) (va_x_v11:quad32) (va_x_v12:quad32)
    (va_x_v13:quad32) (va_x_v14:quad32) (va_x_cr0:cr0_t) (y_0:quad32) (y_auth:quad32) . let va_sM =
    va_upd_cr0 va_x_cr0 (va_upd_vec 14 va_x_v14 (va_upd_vec 13 va_x_v13 (va_upd_vec 12 va_x_v12
    (va_upd_vec 11 va_x_v11 (va_upd_vec 10 va_x_v10 (va_upd_vec 9 va_x_v9 (va_upd_vec 8 va_x_v8
    (va_upd_vec 7 va_x_v7 (va_upd_vec 6 va_x_v6 (va_upd_vec 5 va_x_v5 (va_upd_vec 4 va_x_v4
    (va_upd_vec 3 va_x_v3 (va_upd_vec 2 va_x_v2 (va_upd_vec 1 va_x_v1 (va_upd_vec 0 va_x_v0
    (va_upd_reg 10 va_x_r10 (va_upd_reg 6 va_x_r6 (va_upd_reg 7 va_x_r7 va_s0)))))))))))))))))) in
    va_get_ok va_sM /\ (y_0 == Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0 0 0 /\ (let h_BE
    = Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_s0)) in y_auth == Vale.AES.GHash_BE.ghash_incremental0 h_BE y_0
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    auth_b)) /\ va_get_vec 1 va_sM == y_auth)) ==> va_k va_sM ((y_0, y_auth))))


val va_wpProof_Gcm_auth_bytes : auth_b:buffer128 -> hkeys_b:buffer128 -> h_BE:quad32 ->
  va_s0:va_state -> va_k:(va_state -> (quad32 & quad32) -> Type0)
  -> Ghost (va_state & va_fuel & (quad32 & quad32))
  (requires (va_t_require va_s0 /\ va_wp_Gcm_auth_bytes auth_b hkeys_b h_BE va_s0 va_k))
  (ensures (fun (va_sM, va_f0, va_g) -> va_t_ensure (va_code_Gcm_auth_bytes ()) ([va_Mod_cr0;
    va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9;
    va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec
    2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 6; va_Mod_reg 7]) va_s0 va_k ((va_sM,
    va_f0, va_g))))
[@"opaque_to_smt"]
let va_wpProof_Gcm_auth_bytes auth_b hkeys_b h_BE va_s0 va_k =
  let (va_sM, va_f0, y_0, y_auth) = va_lemma_Gcm_auth_bytes (va_code_Gcm_auth_bytes ()) va_s0
    auth_b hkeys_b h_BE in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_cr0 va_sM (va_update_vec 14 va_sM (va_update_vec 13 va_sM
    (va_update_vec 12 va_sM (va_update_vec 11 va_sM (va_update_vec 10 va_sM (va_update_vec 9 va_sM
    (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5 va_sM
    (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1 va_sM
    (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 6 va_sM (va_update_reg 7 va_sM
    (va_update_ok va_sM va_s0)))))))))))))))))))));
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11;
    va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec
    4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 6;
    va_Mod_reg 7]) va_sM va_s0;
  let va_g = (y_0, y_auth) in
  (va_sM, va_f0, va_g)

[@ "opaque_to_smt" va_qattr]
let va_quick_Gcm_auth_bytes (auth_b:buffer128) (hkeys_b:buffer128) (h_BE:quad32) : (va_quickCode
  (quad32 & quad32) (va_code_Gcm_auth_bytes ())) =
  (va_QProc (va_code_Gcm_auth_bytes ()) ([va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12;
    va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6;
    va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg
    10; va_Mod_reg 6; va_Mod_reg 7]) (va_wp_Gcm_auth_bytes auth_b hkeys_b h_BE)
    (va_wpProof_Gcm_auth_bytes auth_b hkeys_b h_BE))
//--
//-- Gcm_make_length_quad

[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_make_length_quad () =
  (va_Block (va_CCons (va_code_Sl64Imm (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 6) 3) (va_CCons
    (va_code_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) 3) (va_CCons (va_code_Mtvsrdd
    (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 7)) (va_CNil ())))))

[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_make_length_quad () =
  (va_pbool_and (va_codegen_success_Sl64Imm (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 6) 3)
    (va_pbool_and (va_codegen_success_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) 3)
    (va_pbool_and (va_codegen_success_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 6)
    (va_op_reg_opr_reg 7)) (va_ttrue ()))))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_make_length_quad (va_mods:va_mods_t) : (va_quickCode unit
  (va_code_Gcm_make_length_quad ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 227 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 6) 3) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 228 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) 3) (fun (va_s:va_state) _ -> let
    (va_arg13:Vale.Def.Types_s.nat64) = va_get_reg 6 va_old_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 229 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg13 3) (let
    (va_arg12:Vale.Def.Types_s.nat64) = va_get_reg 7 va_old_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 230 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg12 3) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 231 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 6 va_s == va_get_reg 6 va_old_s `op_Multiply` 8) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 232 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 7 va_s == va_get_reg 7 va_old_s `op_Multiply` 8) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 233 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 7)) (va_QEmpty
    (()))))))))))

[@"opaque_to_smt"]
let va_lemma_Gcm_make_length_quad va_b0 va_s0 =
  let (va_mods:va_mods_t) = [va_Mod_vec 9; va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok] in
  let va_qc = va_qcode_Gcm_make_length_quad va_mods in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Gcm_make_length_quad ()) va_qc va_s0
    (fun va_s0 va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 212 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ (label va_range1
    "***** POSTCONDITION NOT MET AT line 221 column 40 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (8 `op_Multiply` va_get_reg 6 va_s0 < pow2_64) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 222 column 40 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (8 `op_Multiply` va_get_reg 7 va_s0 < pow2_64) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 225 column 95 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 9 va_sM == Vale.Def.Words.Four_s.two_two_to_four #Vale.Def.Types_s.nat32
    (Vale.Def.Words_s.Mktwo #(Vale.Def.Words_s.two Vale.Def.Types_s.nat32) (Vale.Def.Words_s.Mktwo
    #Vale.Def.Types_s.nat32 (8 `op_Multiply` va_get_reg 7 va_s0 `op_Modulus` pow2_32) (8
    `op_Multiply` va_get_reg 7 va_s0 `op_Division` pow2_32 `op_Modulus` pow2_32))
    (Vale.Def.Words_s.Mktwo #Vale.Def.Types_s.nat32 (8 `op_Multiply` va_get_reg 6 va_s0
    `op_Modulus` pow2_32) (8 `op_Multiply` va_get_reg 6 va_s0 `op_Division` pow2_32 `op_Modulus`
    pow2_32)))))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_vec 9; va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok]) va_sM va_s0;
  (va_sM, va_fM)


[@"opaque_to_smt"]
let va_wpProof_Gcm_make_length_quad va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Gcm_make_length_quad (va_code_Gcm_make_length_quad ()) va_s0 in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_vec 9 va_sM (va_update_reg 7 va_sM (va_update_reg 6 va_sM
    (va_update_ok va_sM va_s0)))));
  va_lemma_norm_mods ([va_Mod_vec 9; va_Mod_reg 7; va_Mod_reg 6]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

//--
//-- Compute_pad_to_128_bits

val va_code_Compute_pad_to_128_bits : va_dummy:unit -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Compute_pad_to_128_bits () =
  (va_Block (va_CCons (va_IfElse (va_cmp_lt (va_op_cmp_reg 8) (va_const_cmp 8)) (va_Block (va_CCons
    (va_code_LoadImm64 (va_op_reg_opr_reg 10) 8) (va_CCons (va_code_Sub (va_op_reg_opr_reg 10)
    (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8)) (va_CCons (va_code_Sl64Imm (va_op_reg_opr_reg 10)
    (va_op_reg_opr_reg 10) 3) (va_CCons (va_Block (va_CNil ())) (va_CCons (va_code_Mfvsrd
    (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (va_CCons (va_code_Sr64 (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_CCons (va_code_Sl64 (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_CCons (va_code_LoadImm64 (va_op_reg_opr_reg
    10) 0) (va_CCons (va_code_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 10)) (va_CNil ()))))))))))) (va_Block (va_CCons (va_IfElse (va_cmp_eq
    (va_op_cmp_reg 8) (va_const_cmp 8)) (va_Block (va_CCons (va_code_Mfvsrd (va_op_reg_opr_reg 7)
    (va_op_vec_opr_vec 9)) (va_CCons (va_code_LoadImm64 (va_op_reg_opr_reg 10) 0) (va_CCons
    (va_code_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_CNil
    ()))))) (va_Block (va_CCons (va_code_LoadImm64 (va_op_reg_opr_reg 10) 16) (va_CCons
    (va_code_Sub (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8)) (va_CCons
    (va_code_Sl64Imm (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) 3) (va_CCons (va_Block (va_CNil
    ())) (va_CCons (va_code_Mfvsrld (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (va_CCons
    (va_code_Sr64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_CCons
    (va_code_Sl64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_CCons
    (va_code_Mfvsrd (va_op_reg_opr_reg 10) (va_op_vec_opr_vec 9)) (va_CCons (va_code_Mtvsrdd
    (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 7)) (va_CNil ()))))))))))))
    (va_CNil ())))) (va_CNil ())))

val va_codegen_success_Compute_pad_to_128_bits : va_dummy:unit -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Compute_pad_to_128_bits () =
  (va_pbool_and (va_pbool_and (va_codegen_success_LoadImm64 (va_op_reg_opr_reg 10) 8) (va_pbool_and
    (va_codegen_success_Sub (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8))
    (va_pbool_and (va_codegen_success_Sl64Imm (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) 3)
    (va_pbool_and (va_codegen_success_Mfvsrd (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9))
    (va_pbool_and (va_codegen_success_Sr64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 10)) (va_pbool_and (va_codegen_success_Sl64 (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_pbool_and (va_codegen_success_LoadImm64
    (va_op_reg_opr_reg 10) 0) (va_pbool_and (va_codegen_success_Mtvsrdd (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_pbool_and (va_codegen_success_Mfvsrd
    (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (va_pbool_and (va_codegen_success_LoadImm64
    (va_op_reg_opr_reg 10) 0) (va_pbool_and (va_codegen_success_Mtvsrdd (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_pbool_and (va_codegen_success_LoadImm64
    (va_op_reg_opr_reg 10) 16) (va_pbool_and (va_codegen_success_Sub (va_op_reg_opr_reg 10)
    (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8)) (va_pbool_and (va_codegen_success_Sl64Imm
    (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) 3) (va_pbool_and (va_codegen_success_Mfvsrld
    (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (va_pbool_and (va_codegen_success_Sr64
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_pbool_and
    (va_codegen_success_Sl64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10))
    (va_pbool_and (va_codegen_success_Mfvsrd (va_op_reg_opr_reg 10) (va_op_vec_opr_vec 9))
    (va_codegen_success_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg
    7)))))))))))))))))))) (va_ttrue ()))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Compute_pad_to_128_bits (va_mods:va_mods_t) : (va_quickCode unit
  (va_code_Compute_pad_to_128_bits ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 247 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Poly1305.Math.lemma_poly_bits64 ()) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 248 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_qIf va_mods (Cmp_lt (va_op_cmp_reg 8) (va_const_cmp 8)) (qblock va_mods (fun
    (va_s:va_state) -> va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 250 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 8) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 251 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sub (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8)) (va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 252 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) 3) (fun (va_s:va_state) _ ->
    va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 253 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (8 - va_get_reg 8 va_s >= 0 /\ 8 - va_get_reg 8 va_s <= 18446744073709551615) (fun _ -> let
    (va_arg57:Vale.Def.Types_s.nat64) = 8 - va_get_reg 8 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 253 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg57 3) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 254 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 10 va_s == (8 - va_get_reg 8 va_s) `op_Multiply` 8) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 255 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mfvsrd (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (fun (va_s:va_state) _ -> let
    (va_arg56:Prims.nat) = va_get_reg 10 va_s in let (va_arg55:Vale.Def.Types_s.nat64) = va_get_reg
    7 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 256 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishr_64 va_arg55 va_arg56) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 257 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sr64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (fun
    (va_s:va_state) _ -> let (va_arg54:Prims.nat) = va_get_reg 10 va_s in let
    (va_arg53:Vale.Def.Types_s.nat64) = va_get_reg 7 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 258 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg53 va_arg54) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 259 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_QSeq
    va_range1
    "***** PRECONDITION NOT MET AT line 262 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 0) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 263 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (fun
    (va_s:va_state) _ -> va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 265 column 27 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.lemma_nat_to_two32 ()) (let (va_arg52:Prims.int) = va_get_reg
    8 va_s in let (va_arg51:Vale.Def.Types_s.quad32) = va_get_vec 9 va_old_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 266 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_helpers_BE.pad_to_128_bits_upper va_arg51 va_arg52) (va_QEmpty
    (())))))))))))))))))) (qblock va_mods (fun (va_s:va_state) -> va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 267 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_qIf va_mods (Cmp_eq (va_op_cmp_reg 8) (va_const_cmp 8)) (qblock va_mods (fun
    (va_s:va_state) -> va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 268 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mfvsrd (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 269 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 0) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 270 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (fun
    (va_s:va_state) _ -> va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 272 column 27 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.lemma_nat_to_two32 ()) (let (va_arg58:Vale.Def.Types_s.quad32)
    = va_get_vec 9 va_old_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 273 column 32 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_helpers_BE.pad_to_128_bits_lower_8 va_arg58) (va_QEmpty
    (())))))))) (qblock va_mods (fun (va_s:va_state) -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 275 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 8 va_s - 8 > 0) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 277 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 16) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 278 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sub (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 8)) (va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 279 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 10) 3) (fun (va_s:va_state) _ ->
    va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 280 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (16 - va_get_reg 8 va_s >= 0 /\ 16 - va_get_reg 8 va_s <= 18446744073709551615) (fun _ -> let
    (va_arg65:Vale.Def.Types_s.nat64) = 16 - va_get_reg 8 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 280 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg65 3) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 281 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 10 va_s == (16 - va_get_reg 8 va_s) `op_Multiply` 8) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 282 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mfvsrld (va_op_reg_opr_reg 7) (va_op_vec_opr_vec 9)) (fun (va_s:va_state) _ -> let
    (va_arg64:Prims.nat) = va_get_reg 10 va_s in let (va_arg63:Vale.Def.Types_s.nat64) = va_get_reg
    7 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 283 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishr_64 va_arg63 va_arg64) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 284 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sr64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (fun
    (va_s:va_state) _ -> let (va_arg62:Prims.nat) = va_get_reg 10 va_s in let
    (va_arg61:Vale.Def.Types_s.nat64) = va_get_reg 7 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 285 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg61 va_arg62) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 286 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64 (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 10)) (va_QSeq
    va_range1
    "***** PRECONDITION NOT MET AT line 289 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mfvsrd (va_op_reg_opr_reg 10) (va_op_vec_opr_vec 9)) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 290 column 16 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Mtvsrdd (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 10) (va_op_reg_opr_reg 7)) (fun
    (va_s:va_state) _ -> va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 292 column 27 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.lemma_nat_to_two32 ()) (let (va_arg60:Prims.int) = va_get_reg
    8 va_s in let (va_arg59:Vale.Def.Types_s.quad32) = va_get_vec 9 va_old_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 293 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_helpers_BE.pad_to_128_bits_lower va_arg59 va_arg60) (va_QEmpty
    (())))))))))))))))))))) (fun (va_s:va_state) va_g -> va_QEmpty (()))))) (fun (va_s:va_state)
    va_g -> va_QEmpty (())))))


val va_lemma_Compute_pad_to_128_bits : va_b0:va_code -> va_s0:va_state
  -> Ghost (va_state & va_fuel)
  (requires (va_require_total va_b0 (va_code_Compute_pad_to_128_bits ()) va_s0 /\ va_get_ok va_s0
    /\ (0 < va_get_reg 8 va_s0 /\ va_get_reg 8 va_s0 < 16)))
  (ensures (fun (va_sM, va_fM) -> va_ensure_total va_b0 va_s0 va_sM va_fM /\ va_get_ok va_sM /\
    (let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits (FStar.Seq.Base.slice #nat8
    (Vale.Arch.Types.be_quad32_to_bytes (va_get_vec 9 va_s0)) 0 (va_get_reg 8 va_s0)) in
    FStar.Seq.Base.length #Vale.Def.Types_s.nat8 padded_bytes = 16 /\ va_get_vec 9 va_sM =
    Vale.Def.Types_s.be_bytes_to_quad32 padded_bytes) /\ va_state_eq va_sM (va_update_cr0 va_sM
    (va_update_reg 10 va_sM (va_update_reg 7 va_sM (va_update_vec 9 va_sM (va_update_ok va_sM
    va_s0)))))))
[@"opaque_to_smt"]
let va_lemma_Compute_pad_to_128_bits va_b0 va_s0 =
  let (va_mods:va_mods_t) = [va_Mod_cr0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_vec 9; va_Mod_ok] in
  let va_qc = va_qcode_Compute_pad_to_128_bits va_mods in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Compute_pad_to_128_bits ()) va_qc va_s0
    (fun va_s0 va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 236 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 244 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits (FStar.Seq.Base.slice #nat8
    (Vale.Arch.Types.be_quad32_to_bytes (va_get_vec 9 va_s0)) 0 (va_get_reg 8 va_s0)) in label
    va_range1
    "***** POSTCONDITION NOT MET AT line 245 column 75 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (FStar.Seq.Base.length #Vale.Def.Types_s.nat8 padded_bytes = 16 /\ va_get_vec 9 va_sM =
    Vale.Def.Types_s.be_bytes_to_quad32 padded_bytes))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_vec 9; va_Mod_ok]) va_sM
    va_s0;
  (va_sM, va_fM)

[@ va_qattr]
let va_wp_Compute_pad_to_128_bits (va_s0:va_state) (va_k:(va_state -> unit -> Type0)) : Type0 =
  (va_get_ok va_s0 /\ (0 < va_get_reg 8 va_s0 /\ va_get_reg 8 va_s0 < 16) /\ (forall
    (va_x_v9:quad32) (va_x_r7:nat64) (va_x_r10:nat64) (va_x_cr0:cr0_t) . let va_sM = va_upd_cr0
    va_x_cr0 (va_upd_reg 10 va_x_r10 (va_upd_reg 7 va_x_r7 (va_upd_vec 9 va_x_v9 va_s0))) in
    va_get_ok va_sM /\ (let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits (FStar.Seq.Base.slice
    #nat8 (Vale.Arch.Types.be_quad32_to_bytes (va_get_vec 9 va_s0)) 0 (va_get_reg 8 va_s0)) in
    FStar.Seq.Base.length #Vale.Def.Types_s.nat8 padded_bytes = 16 /\ va_get_vec 9 va_sM =
    Vale.Def.Types_s.be_bytes_to_quad32 padded_bytes) ==> va_k va_sM (())))


val va_wpProof_Compute_pad_to_128_bits : va_s0:va_state -> va_k:(va_state -> unit -> Type0)
  -> Ghost (va_state & va_fuel & unit)
  (requires (va_t_require va_s0 /\ va_wp_Compute_pad_to_128_bits va_s0 va_k))
  (ensures (fun (va_sM, va_f0, va_g) -> va_t_ensure (va_code_Compute_pad_to_128_bits ())
    ([va_Mod_cr0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_vec 9]) va_s0 va_k ((va_sM, va_f0, va_g))))
[@"opaque_to_smt"]
let va_wpProof_Compute_pad_to_128_bits va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Compute_pad_to_128_bits (va_code_Compute_pad_to_128_bits ()) va_s0
    in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_cr0 va_sM (va_update_reg 10 va_sM (va_update_reg 7 va_sM
    (va_update_vec 9 va_sM (va_update_ok va_sM va_s0))))));
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_vec 9]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

[@ "opaque_to_smt" va_qattr]
let va_quick_Compute_pad_to_128_bits () : (va_quickCode unit (va_code_Compute_pad_to_128_bits ())) =
  (va_QProc (va_code_Compute_pad_to_128_bits ()) ([va_Mod_cr0; va_Mod_reg 10; va_Mod_reg 7;
    va_Mod_vec 9]) va_wp_Compute_pad_to_128_bits va_wpProof_Compute_pad_to_128_bits)
//--
//-- Ghash_extra_bytes

[@ "opaque_to_smt" va_qattr]
let va_code_Ghash_extra_bytes () =
  (va_Block (va_CCons (va_code_Compute_pad_to_128_bits ()) (va_CCons (va_code_Ghash_register ())
    (va_CNil ()))))

[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Ghash_extra_bytes () =
  (va_pbool_and (va_codegen_success_Compute_pad_to_128_bits ()) (va_pbool_and
    (va_codegen_success_Ghash_register ()) (va_ttrue ())))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Ghash_extra_bytes (va_mods:va_mods_t) (hkeys_b:buffer128) (total_bytes:nat)
  (old_hash:quad32) (h_BE:quad32) (completed_quads:(seq quad32)) : (va_quickCode unit
  (va_code_Ghash_extra_bytes ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in let (final_quad:quad32)
    = va_get_vec 9 va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 336 column 28 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Compute_pad_to_128_bits ()) (fun (va_s:va_state) _ -> let (final_quad_padded:quad32)
    = va_get_vec 9 va_s in let (y_prev:quad32) = va_get_vec 1 va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 340 column 19 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_register hkeys_b h_BE y_prev) (fun (va_s:va_state) _ -> let
    (va_arg19:Prims.nat) = total_bytes in let (va_arg18:Vale.Def.Types_s.quad32) =
    final_quad_padded in let (va_arg17:Vale.Def.Types_s.quad32) = final_quad in let
    (va_arg16:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = completed_quads in let
    (va_arg15:Vale.Def.Types_s.quad32) = va_get_vec 1 va_s in let
    (va_arg14:Vale.Def.Types_s.quad32) = y_prev in let (va_arg13:Vale.Def.Types_s.quad32) =
    old_hash in let (va_arg12:Vale.Def.Types_s.quad32) = h_BE in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 342 column 51 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.lemma_ghash_incremental_bytes_extra_helper_alt va_arg12
    va_arg13 va_arg14 va_arg15 va_arg16 va_arg17 va_arg18 va_arg19) (va_QEmpty (()))))))

[@"opaque_to_smt"]
let va_lemma_Ghash_extra_bytes va_b0 va_s0 hkeys_b total_bytes old_hash h_BE completed_quads =
  let (va_mods:va_mods_t) = [va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_ok] in
  let va_qc = va_qcode_Ghash_extra_bytes va_mods hkeys_b total_bytes old_hash h_BE completed_quads
    in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Ghash_extra_bytes ()) va_qc va_s0 (fun
    va_s0 va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 297 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 328 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let raw_quads = FStar.Seq.Base.append #quad32 completed_quads (FStar.Seq.Base.create #quad32 1
    (va_get_vec 9 va_s0)) in label va_range1
    "***** POSTCONDITION NOT MET AT line 329 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let input_bytes = FStar.Seq.Base.slice #Vale.Def.Words_s.nat8
    (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE (Vale.Def.Words.Seq_s.seq_four_to_seq_BE
    #Vale.Def.Words_s.nat32 raw_quads)) 0 total_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 330 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits input_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 331 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let input_quads = Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 333 column 80 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (total_bytes > 0 ==> l_and (FStar.Seq.Base.length #Vale.Def.Types_s.quad32 input_quads > 0)
    (va_get_vec 1 va_sM == Vale.AES.GHash_BE.ghash_incremental h_BE old_hash input_quads))))))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_ok]) va_sM va_s0;
  (va_sM, va_fM)


[@"opaque_to_smt"]
let va_wpProof_Ghash_extra_bytes hkeys_b total_bytes old_hash h_BE completed_quads va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Ghash_extra_bytes (va_code_Ghash_extra_bytes ()) va_s0 hkeys_b
    total_bytes old_hash h_BE completed_quads in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_cr0 va_sM (va_update_vec 10 va_sM (va_update_vec 9 va_sM
    (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5 va_sM
    (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1 va_sM
    (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 7 va_sM (va_update_ok va_sM
    va_s0))))))))))))))));
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 7]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

//--
//-- Gcm_extra_bytes

val va_code_Gcm_extra_bytes : alg:algorithm -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_extra_bytes alg =
  (va_Block (va_CCons (va_code_Vmr (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 7)) (va_CCons
    (va_code_AESEncryptBlock alg) (va_CCons (va_code_Load128_byte16_buffer
    (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 3) Secret) (va_CCons
    (va_code_Vxor (va_op_vec_opr_vec 9) (va_op_vec_opr_vec 9) (va_op_vec_opr_vec 0)) (va_CCons
    (va_code_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 3) Secret) (va_CCons (va_code_Ghash_extra_bytes ()) (va_CNil ()))))))))

val va_codegen_success_Gcm_extra_bytes : alg:algorithm -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_extra_bytes alg =
  (va_pbool_and (va_codegen_success_Vmr (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 7)) (va_pbool_and
    (va_codegen_success_AESEncryptBlock alg) (va_pbool_and
    (va_codegen_success_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 3) Secret) (va_pbool_and (va_codegen_success_Vxor (va_op_vec_opr_vec 9)
    (va_op_vec_opr_vec 9) (va_op_vec_opr_vec 0)) (va_pbool_and
    (va_codegen_success_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 3) Secret) (va_pbool_and (va_codegen_success_Ghash_extra_bytes ()) (va_ttrue
    ())))))))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_extra_bytes (va_mods:va_mods_t) (alg:algorithm) (inout_b:buffer128) (key:(seq
  nat32)) (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (total_bytes:nat)
  (old_hash:quad32) (completed_quads:(seq quad32)) (h_BE:quad32) : (va_quickCode unit
  (va_code_Gcm_extra_bytes alg)) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in let (len:(va_int_range
    1 1)) = 1 in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 401 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vmr (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 7)) (fun (va_s:va_state) _ -> va_QSeq
    va_range1
    "***** PRECONDITION NOT MET AT line 402 column 20 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_AESEncryptBlock alg (va_get_vec 7 va_s) key round_keys keys_b) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 404 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 3) Secret inout_b 0) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 405 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vxor (va_op_vec_opr_vec 9) (va_op_vec_opr_vec 9) (va_op_vec_opr_vec 0)) (va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 406 column 27 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 5) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 3) Secret inout_b 0) (fun (va_s:va_state) _ -> let (hash_input:quad32) =
    va_get_vec 9 va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 410 column 22 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_extra_bytes hkeys_b total_bytes old_hash h_BE completed_quads) (fun
    (va_s:va_state) _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 412 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (FStar.Seq.Base.equal #Vale.Def.Types_s.quad32 (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_s) inout_b)) (FStar.Seq.Base.create #quad32 1
    hash_input)) (va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 413 column 24 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCTR_BE.gctr_partial_reveal ()) (va_QEmpty (())))))))))))


val va_lemma_Gcm_extra_bytes : va_b0:va_code -> va_s0:va_state -> alg:algorithm ->
  inout_b:buffer128 -> key:(seq nat32) -> round_keys:(seq quad32) -> keys_b:buffer128 ->
  hkeys_b:buffer128 -> total_bytes:nat -> old_hash:quad32 -> completed_quads:(seq quad32) ->
  h_BE:quad32
  -> Ghost (va_state & va_fuel)
  (requires (va_require_total va_b0 (va_code_Gcm_extra_bytes alg) va_s0 /\ va_get_ok va_s0 /\ (let
    (len:(va_int_range 1 1)) = 1 in Vale.PPC64LE.Decls.validDstAddrs128 (va_get_mem_heaplet 5
    va_s0) (va_get_reg 3 va_s0) inout_b len (va_get_mem_layout va_s0) Secret /\ len ==
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 inout_b /\ aes_reqs alg key
    round_keys keys_b (va_get_reg 4 va_s0) (va_get_mem_heaplet 0 va_s0) (va_get_mem_layout va_s0)
    /\ Vale.AES.GHash_BE.hkeys_reqs_priv (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0) hkeys_b)) h_BE /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg 5 va_s0) hkeys_b 3
    (va_get_mem_layout va_s0) Secret /\ va_get_vec 1 va_s0 == Vale.AES.GHash_BE.ghash_incremental0
    h_BE old_hash completed_quads /\ FStar.Seq.Base.length #quad32 completed_quads == total_bytes
    `op_Division` 16 /\ total_bytes < 16 `op_Multiply` FStar.Seq.Base.length #quad32
    completed_quads + 16 /\ va_get_reg 8 va_s0 == total_bytes `op_Modulus` 16 /\ total_bytes
    `op_Modulus` 16 =!= 0 /\ (0 < total_bytes /\ total_bytes < 16 `op_Multiply`
    Vale.AES.GCM_helpers_BE.bytes_to_quad_size total_bytes) /\ 16 `op_Multiply`
    (Vale.AES.GCM_helpers_BE.bytes_to_quad_size total_bytes - 1) < total_bytes)))
  (ensures (fun (va_sM, va_fM) -> va_ensure_total va_b0 va_s0 va_sM va_fM /\ va_get_ok va_sM /\
    (let (len:(va_int_range 1 1)) = 1 in Vale.PPC64LE.Decls.modifies_buffer128 inout_b
    (va_get_mem_heaplet 5 va_s0) (va_get_mem_heaplet 5 va_sM) /\ Vale.AES.GCTR_BE.gctr_partial alg
    len (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5
    va_s0) inout_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 5 va_sM) inout_b)) key (va_get_vec 7 va_s0) /\ (let raw_quads =
    FStar.Seq.Base.append #quad32 completed_quads (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_sM) inout_b)) in let input_bytes =
    FStar.Seq.Base.slice #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_quads)) 0 total_bytes in
    let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits input_bytes in let input_quads =
    Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_bytes in l_and (FStar.Seq.Base.length
    #Vale.Def.Types_s.quad32 input_quads > 0) (va_get_vec 1 va_sM ==
    Vale.AES.GHash_BE.ghash_incremental h_BE old_hash input_quads))) /\ va_state_eq va_sM
    (va_update_mem_heaplet 5 va_sM (va_update_cr0 va_sM (va_update_vec 10 va_sM (va_update_vec 9
    va_sM (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5
    va_sM (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1
    va_sM (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 7 va_sM (va_update_ok va_sM
    (va_update_mem va_sM va_s0)))))))))))))))))))
[@"opaque_to_smt"]
let va_lemma_Gcm_extra_bytes va_b0 va_s0 alg inout_b key round_keys keys_b hkeys_b total_bytes
  old_hash completed_quads h_BE =
  let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 5; va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9;
    va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec
    2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_ok; va_Mod_mem] in
  let va_qc = va_qcode_Gcm_extra_bytes va_mods alg inout_b key round_keys keys_b hkeys_b
    total_bytes old_hash completed_quads h_BE in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Gcm_extra_bytes alg) va_qc va_s0 (fun
    va_s0 va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 345 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ (let (len:(va_int_range 1 1)) = 1 in label va_range1
    "***** POSTCONDITION NOT MET AT line 389 column 55 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.PPC64LE.Decls.modifies_buffer128 inout_b (va_get_mem_heaplet 5 va_s0) (va_get_mem_heaplet
    5 va_sM)) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 392 column 147 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.AES.GCTR_BE.gctr_partial alg len (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_s0) inout_b))
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_sM)
    inout_b)) key (va_get_vec 7 va_s0)) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 395 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let raw_quads = FStar.Seq.Base.append #quad32 completed_quads
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_sM)
    inout_b)) in label va_range1
    "***** POSTCONDITION NOT MET AT line 396 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let input_bytes = FStar.Seq.Base.slice #Vale.Def.Words_s.nat8
    (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE (Vale.Def.Words.Seq_s.seq_four_to_seq_BE
    #Vale.Def.Words_s.nat32 raw_quads)) 0 total_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 397 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits input_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 398 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let input_quads = Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_bytes in label va_range1
    "***** POSTCONDITION NOT MET AT line 399 column 91 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (l_and (FStar.Seq.Base.length #Vale.Def.Types_s.quad32 input_quads > 0) (va_get_vec 1 va_sM ==
    Vale.AES.GHash_BE.ghash_incremental h_BE old_hash input_quads)))))))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_mem_heaplet 5; va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8;
    va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec
    1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_ok; va_Mod_mem]) va_sM va_s0;
  (va_sM, va_fM)

[@ va_qattr]
let va_wp_Gcm_extra_bytes (alg:algorithm) (inout_b:buffer128) (key:(seq nat32)) (round_keys:(seq
  quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (total_bytes:nat) (old_hash:quad32)
  (completed_quads:(seq quad32)) (h_BE:quad32) (va_s0:va_state) (va_k:(va_state -> unit -> Type0))
  : Type0 =
  (va_get_ok va_s0 /\ (let (len:(va_int_range 1 1)) = 1 in Vale.PPC64LE.Decls.validDstAddrs128
    (va_get_mem_heaplet 5 va_s0) (va_get_reg 3 va_s0) inout_b len (va_get_mem_layout va_s0) Secret
    /\ len == Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 inout_b /\ aes_reqs
    alg key round_keys keys_b (va_get_reg 4 va_s0) (va_get_mem_heaplet 0 va_s0) (va_get_mem_layout
    va_s0) /\ Vale.AES.GHash_BE.hkeys_reqs_priv (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0) hkeys_b)) h_BE /\
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0 va_s0) (va_get_reg 5 va_s0) hkeys_b 3
    (va_get_mem_layout va_s0) Secret /\ va_get_vec 1 va_s0 == Vale.AES.GHash_BE.ghash_incremental0
    h_BE old_hash completed_quads /\ FStar.Seq.Base.length #quad32 completed_quads == total_bytes
    `op_Division` 16 /\ total_bytes < 16 `op_Multiply` FStar.Seq.Base.length #quad32
    completed_quads + 16 /\ va_get_reg 8 va_s0 == total_bytes `op_Modulus` 16 /\ total_bytes
    `op_Modulus` 16 =!= 0 /\ (0 < total_bytes /\ total_bytes < 16 `op_Multiply`
    Vale.AES.GCM_helpers_BE.bytes_to_quad_size total_bytes) /\ 16 `op_Multiply`
    (Vale.AES.GCM_helpers_BE.bytes_to_quad_size total_bytes - 1) < total_bytes) /\ (forall
    (va_x_mem:vale_heap) (va_x_r7:nat64) (va_x_r10:nat64) (va_x_v0:quad32) (va_x_v1:quad32)
    (va_x_v2:quad32) (va_x_v3:quad32) (va_x_v4:quad32) (va_x_v5:quad32) (va_x_v6:quad32)
    (va_x_v7:quad32) (va_x_v8:quad32) (va_x_v9:quad32) (va_x_v10:quad32) (va_x_cr0:cr0_t)
    (va_x_heap5:vale_heap) . let va_sM = va_upd_mem_heaplet 5 va_x_heap5 (va_upd_cr0 va_x_cr0
    (va_upd_vec 10 va_x_v10 (va_upd_vec 9 va_x_v9 (va_upd_vec 8 va_x_v8 (va_upd_vec 7 va_x_v7
    (va_upd_vec 6 va_x_v6 (va_upd_vec 5 va_x_v5 (va_upd_vec 4 va_x_v4 (va_upd_vec 3 va_x_v3
    (va_upd_vec 2 va_x_v2 (va_upd_vec 1 va_x_v1 (va_upd_vec 0 va_x_v0 (va_upd_reg 10 va_x_r10
    (va_upd_reg 7 va_x_r7 (va_upd_mem va_x_mem va_s0))))))))))))))) in va_get_ok va_sM /\ (let
    (len:(va_int_range 1 1)) = 1 in Vale.PPC64LE.Decls.modifies_buffer128 inout_b
    (va_get_mem_heaplet 5 va_s0) (va_get_mem_heaplet 5 va_sM) /\ Vale.AES.GCTR_BE.gctr_partial alg
    len (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5
    va_s0) inout_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 5 va_sM) inout_b)) key (va_get_vec 7 va_s0) /\ (let raw_quads =
    FStar.Seq.Base.append #quad32 completed_quads (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 5 va_sM) inout_b)) in let input_bytes =
    FStar.Seq.Base.slice #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_quads)) 0 total_bytes in
    let padded_bytes = Vale.AES.GCTR_BE_s.pad_to_128_bits input_bytes in let input_quads =
    Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_bytes in l_and (FStar.Seq.Base.length
    #Vale.Def.Types_s.quad32 input_quads > 0) (va_get_vec 1 va_sM ==
    Vale.AES.GHash_BE.ghash_incremental h_BE old_hash input_quads))) ==> va_k va_sM (())))


val va_wpProof_Gcm_extra_bytes : alg:algorithm -> inout_b:buffer128 -> key:(seq nat32) ->
  round_keys:(seq quad32) -> keys_b:buffer128 -> hkeys_b:buffer128 -> total_bytes:nat ->
  old_hash:quad32 -> completed_quads:(seq quad32) -> h_BE:quad32 -> va_s0:va_state ->
  va_k:(va_state -> unit -> Type0)
  -> Ghost (va_state & va_fuel & unit)
  (requires (va_t_require va_s0 /\ va_wp_Gcm_extra_bytes alg inout_b key round_keys keys_b hkeys_b
    total_bytes old_hash completed_quads h_BE va_s0 va_k))
  (ensures (fun (va_sM, va_f0, va_g) -> va_t_ensure (va_code_Gcm_extra_bytes alg)
    ([va_Mod_mem_heaplet 5; va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_mem]) va_s0 va_k ((va_sM, va_f0, va_g))))
[@"opaque_to_smt"]
let va_wpProof_Gcm_extra_bytes alg inout_b key round_keys keys_b hkeys_b total_bytes old_hash
  completed_quads h_BE va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Gcm_extra_bytes (va_code_Gcm_extra_bytes alg) va_s0 alg inout_b key
    round_keys keys_b hkeys_b total_bytes old_hash completed_quads h_BE in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_mem_heaplet 5 va_sM (va_update_cr0 va_sM (va_update_vec 10
    va_sM (va_update_vec 9 va_sM (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6
    va_sM (va_update_vec 5 va_sM (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2
    va_sM (va_update_vec 1 va_sM (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 7
    va_sM (va_update_ok va_sM (va_update_mem va_sM va_s0))))))))))))))))));
  va_lemma_norm_mods ([va_Mod_mem_heaplet 5; va_Mod_cr0; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8;
    va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec
    1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_mem]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

[@ "opaque_to_smt" va_qattr]
let va_quick_Gcm_extra_bytes (alg:algorithm) (inout_b:buffer128) (key:(seq nat32)) (round_keys:(seq
  quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (total_bytes:nat) (old_hash:quad32)
  (completed_quads:(seq quad32)) (h_BE:quad32) : (va_quickCode unit (va_code_Gcm_extra_bytes alg)) =
  (va_QProc (va_code_Gcm_extra_bytes alg) ([va_Mod_mem_heaplet 5; va_Mod_cr0; va_Mod_vec 10;
    va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec
    3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 7; va_Mod_mem])
    (va_wp_Gcm_extra_bytes alg inout_b key round_keys keys_b hkeys_b total_bytes old_hash
    completed_quads h_BE) (va_wpProof_Gcm_extra_bytes alg inout_b key round_keys keys_b hkeys_b
    total_bytes old_hash completed_quads h_BE))
//--
//-- Gcm_blocks_auth

[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_blocks_auth () =
  (va_Block (va_CCons (va_code_Sl64Imm (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 6) 4) (va_CCons
    (va_code_Gcm_auth_bytes ()) (va_CCons (va_Block (va_CNil ())) (va_CCons (va_IfElse (va_cmp_gt
    (va_op_cmp_reg 9) (va_op_cmp_reg 8)) (va_Block (va_CCons (va_code_Load128_byte16_buffer
    (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 9) (va_op_reg_opr_reg 4) Secret) (va_CCons
    (va_code_LoadImm64 (va_op_reg_opr_reg 10) 15) (va_CCons (va_code_And (va_op_reg_opr_reg 8)
    (va_op_reg_opr_reg 9) (va_op_reg_opr_reg 10)) (va_CCons (va_code_Ghash_extra_bytes ())
    (va_CCons (va_Block (va_CNil ())) (va_CNil ()))))))) (va_Block (va_CNil ()))) (va_CNil ()))))))

[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_blocks_auth () =
  (va_pbool_and (va_codegen_success_Sl64Imm (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 6) 4)
    (va_pbool_and (va_codegen_success_Gcm_auth_bytes ()) (va_pbool_and (va_pbool_and
    (va_codegen_success_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 4) Secret) (va_pbool_and (va_codegen_success_LoadImm64 (va_op_reg_opr_reg
    10) 15) (va_pbool_and (va_codegen_success_And (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 9)
    (va_op_reg_opr_reg 10)) (va_codegen_success_Ghash_extra_bytes ())))) (va_ttrue ()))))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_blocks_auth (va_mods:va_mods_t) (auth_b:buffer128) (abytes_b:buffer128)
  (hkeys_b:buffer128) (h_BE:quad32) : (va_quickCode ((seq quad32)) (va_code_Gcm_blocks_auth ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 461 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Sl64Imm (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 6) 4) (fun (va_s:va_state) _ -> let
    (va_arg44:Vale.Def.Types_s.nat64) = va_get_reg 6 va_s in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 462 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.Types_helpers.lemma_ishl_64 va_arg44 4) (va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 463 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 8 va_s == va_get_reg 6 va_s `op_Multiply` 16) (let (h_BE:Vale.Def.Types_s.quad32) =
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_old_s)) in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 466 column 5 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_auth_bytes auth_b hkeys_b h_BE) (fun (va_s:va_state) va_g -> let ((y_0:quad32),
    (y_auth:quad32)) = va_g in let (y_auth_bytes:quad32) = y_auth in let
    (auth_quad_seq_len:(va_int_range 0 18446744073709551615)) = va_if (va_get_reg 9 va_old_s <=
    FStar.Seq.Base.length #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b))))) (fun _ -> va_get_reg 9 va_old_s) (fun _ -> 0) in va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 470 column 19 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    ((fun a_1582 (s_1583:(FStar.Seq.Base.seq a_1582)) (i_1584:Prims.nat) (j_1585:Prims.nat) -> let
    (j_1545:Prims.nat) = j_1585 in Prims.b2t (Prims.op_AmpAmp (Prims.op_LessThanOrEqual i_1584
    j_1545) (Prims.op_LessThanOrEqual j_1545 (FStar.Seq.Base.length #a_1582 s_1583))))
    Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b)))) 0 auth_quad_seq_len) (fun _ -> let (auth_quad_seq:(seq quad32)) =
    Vale.Def.Types_s.be_bytes_to_seq_quad32 (Vale.AES.GCTR_BE_s.pad_to_128_bits
    (FStar.Seq.Base.slice #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b)))) 0 auth_quad_seq_len)) in let (va_arg43:Vale.Def.Types_s.nat64) = va_get_reg 9 va_s
    in let (va_arg42:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b) in let (va_arg41:Vale.Def.Types_s.quad32) = y_auth in let
    (va_arg40:Vale.Def.Types_s.quad32) = y_0 in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 473 column 42 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.ghash_incremental_bytes_pure_no_extra va_arg40 va_arg41 h_BE
    va_arg42 va_arg43) (va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 476 column 33 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.be_bytes_to_seq_quad32_empty ()) (let
    (va_arg39:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b) in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 477 column 40 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Arch.Types.lemma_be_seq_quad32_to_bytes_length va_arg39) (va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 479 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_qIf va_mods (Cmp_gt (va_op_cmp_reg 9) (va_op_cmp_reg 8)) (qblock va_mods (fun
    (va_s:va_state) -> va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 481 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 9)
    (va_op_reg_opr_reg 4) Secret abytes_b 0) (fun (va_s:va_state) _ -> va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 482 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.Poly1305.Math.lemma_poly_bits64 ()) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 483 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 10) 15) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 484 column 12 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_And (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 9) (va_op_reg_opr_reg 10)) (fun
    (va_s:va_state) _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 485 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_reg 8 va_s == va_get_reg 9 va_old_s `op_Modulus` 16) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 487 column 26 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_extra_bytes hkeys_b (va_get_reg 9 va_s) y_0 h_BE
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s)
    auth_b))) (fun (va_s:va_state) _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 488 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (FStar.Seq.Base.equal #Vale.Def.Types_s.quad32 (FStar.Seq.Base.create #Vale.Def.Types_s.quad32
    1 (Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read abytes_b 0
    (va_get_mem_heaplet 6 va_s)))) (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6 va_s) abytes_b))) (let y_auth_bytes = va_get_vec
    1 va_s in let (raw_auth_quads:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    FStar.Seq.Base.append #Vale.Def.Types_s.quad32 (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s) auth_b))
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6
    va_old_s) abytes_b)) in va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 492 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    ((fun a_1582 (s_1583:(FStar.Seq.Base.seq a_1582)) (i_1584:Prims.nat) (j_1585:Prims.nat) -> let
    (j_1545:Prims.nat) = j_1585 in Prims.b2t (Prims.op_AmpAmp (Prims.op_LessThanOrEqual i_1584
    j_1545) (Prims.op_LessThanOrEqual j_1545 (FStar.Seq.Base.length #a_1582 s_1583))))
    Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_auth_quads)) 0 (va_get_reg
    9 va_old_s)) (fun _ -> let (auth_input_bytes:(FStar.Seq.Base.seq Vale.Def.Words_s.nat8)) =
    FStar.Seq.Base.slice #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 raw_auth_quads)) 0 (va_get_reg
    9 va_old_s) in let (padded_auth_bytes:(FStar.Seq.Base.seq Vale.Def.Types_s.nat8)) =
    Vale.AES.GCTR_BE_s.pad_to_128_bits auth_input_bytes in let (auth_quad_seq:(seq quad32)) =
    Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_auth_bytes in va_QEmpty ((auth_quad_seq,
    y_auth_bytes)))))))))))) (qblock va_mods (fun (va_s:va_state) -> va_QEmpty ((auth_quad_seq,
    y_auth_bytes))))) (fun (va_s:va_state) va_g -> let ((auth_quad_seq:(seq quad32)),
    (y_auth_bytes:quad32)) = va_g in va_QEmpty ((auth_quad_seq)))))))))))))

[@"opaque_to_smt"]
let va_lemma_Gcm_blocks_auth va_b0 va_s0 auth_b abytes_b hkeys_b h_BE =
  let (va_mods:va_mods_t) = [va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec
    11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5;
    va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg
    8; va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok] in
  let va_qc = va_qcode_Gcm_blocks_auth va_mods auth_b abytes_b hkeys_b h_BE in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Gcm_blocks_auth ()) va_qc va_s0 (fun
    va_s0 va_sM va_g -> let auth_quad_seq = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 416 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 453 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let auth_abytes_quads = FStar.Seq.Base.append #Vale.Def.Types_s.quad32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_sM)
    auth_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet
    6 va_s0) abytes_b)) in label va_range1
    "***** POSTCONDITION NOT MET AT line 454 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let auth_quads = Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 1 va_sM) auth_b) in label va_range1
    "***** POSTCONDITION NOT MET AT line 455 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let (raw_auth_quads:(seq quad32)) = va_if (va_get_reg 9 va_s0 > va_get_reg 6 va_s0
    `op_Multiply` 128 `op_Division` 8) (fun _ -> auth_abytes_quads) (fun _ -> auth_quads) in label
    va_range1
    "***** POSTCONDITION NOT MET AT line 456 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let (auth_input_bytes:(seq nat8)) = FStar.Seq.Base.slice #Vale.Def.Words_s.nat8
    (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE (Vale.Def.Words.Seq_s.seq_four_to_seq_BE
    #Vale.Def.Words_s.nat32 raw_auth_quads)) 0 (va_get_reg 9 va_s0) in label va_range1
    "***** POSTCONDITION NOT MET AT line 457 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (let (padded_auth_bytes:(seq nat8)) = Vale.AES.GCTR_BE_s.pad_to_128_bits auth_input_bytes in
    label va_range1
    "***** POSTCONDITION NOT MET AT line 458 column 67 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (auth_quad_seq == Vale.Def.Types_s.be_bytes_to_seq_quad32 padded_auth_bytes) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 459 column 73 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 1 va_sM == Vale.AES.GHash_BE.ghash_incremental0 h_BE (Vale.Def.Words_s.Mkfour
    #Vale.Def.Types_s.nat32 0 0 0 0) auth_quad_seq))))))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11;
    va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec
    4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 8;
    va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok]) va_sM va_s0;
  let auth_quad_seq = va_g in
  (va_sM, va_fM, auth_quad_seq)


[@"opaque_to_smt"]
let va_wpProof_Gcm_blocks_auth auth_b abytes_b hkeys_b h_BE va_s0 va_k =
  let (va_sM, va_f0, auth_quad_seq) = va_lemma_Gcm_blocks_auth (va_code_Gcm_blocks_auth ()) va_s0
    auth_b abytes_b hkeys_b h_BE in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_cr0 va_sM (va_update_vec 14 va_sM (va_update_vec 13 va_sM
    (va_update_vec 12 va_sM (va_update_vec 11 va_sM (va_update_vec 10 va_sM (va_update_vec 9 va_sM
    (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6 va_sM (va_update_vec 5 va_sM
    (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2 va_sM (va_update_vec 1 va_sM
    (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 8 va_sM (va_update_reg 7 va_sM
    (va_update_reg 6 va_sM (va_update_ok va_sM va_s0))))))))))))))))))))));
  va_lemma_norm_mods ([va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11;
    va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec
    4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 8;
    va_Mod_reg 7; va_Mod_reg 6]) va_sM va_s0;
  let va_g = (auth_quad_seq) in
  (va_sM, va_f0, va_g)

//--
//-- Compute_iv

val va_code_Compute_iv : va_dummy:unit -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Compute_iv () =
  (va_Block (va_CCons (va_IfElse (va_cmp_eq (va_op_cmp_reg 9) (va_const_cmp 12)) (va_Block
    (va_CCons (va_code_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 0)
    (va_op_reg_opr_reg 4) Secret) (va_CCons (va_Block (va_CNil ())) (va_CCons (va_code_Vspltisw
    (va_op_vec_opr_vec 1) 1) (va_CCons (va_code_Vsldoi (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0)
    (va_op_vec_opr_vec 0) 12) (va_CCons (va_code_Vsldoi (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0)
    (va_op_vec_opr_vec 1) 4) (va_CCons (va_code_Store128_byte16_buffer (va_op_heaplet_mem_heaplet
    6) (va_op_vec_opr_vec 0) (va_op_reg_opr_reg 3) Secret) (va_CNil ())))))))) (va_Block (va_CCons
    (va_code_Gcm_blocks_auth ()) (va_CCons (va_code_Move (va_op_reg_opr_reg 6) (va_op_reg_opr_reg
    9)) (va_CCons (va_code_LoadImm64 (va_op_reg_opr_reg 7) 0) (va_CCons
    (va_code_Gcm_make_length_quad ()) (va_CCons (va_code_Ghash_register ()) (va_CCons
    (va_code_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 1)
    (va_op_reg_opr_reg 3) Secret) (va_CNil ()))))))))) (va_CNil ())))

val va_codegen_success_Compute_iv : va_dummy:unit -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Compute_iv () =
  (va_pbool_and (va_pbool_and (va_codegen_success_Load128_byte16_buffer (va_op_heaplet_mem_heaplet
    6) (va_op_vec_opr_vec 0) (va_op_reg_opr_reg 4) Secret) (va_pbool_and
    (va_codegen_success_Vspltisw (va_op_vec_opr_vec 1) 1) (va_pbool_and (va_codegen_success_Vsldoi
    (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) 12) (va_pbool_and
    (va_codegen_success_Vsldoi (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 1) 4)
    (va_pbool_and (va_codegen_success_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 6)
    (va_op_vec_opr_vec 0) (va_op_reg_opr_reg 3) Secret) (va_pbool_and
    (va_codegen_success_Gcm_blocks_auth ()) (va_pbool_and (va_codegen_success_Move
    (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 9)) (va_pbool_and (va_codegen_success_LoadImm64
    (va_op_reg_opr_reg 7) 0) (va_pbool_and (va_codegen_success_Gcm_make_length_quad ())
    (va_pbool_and (va_codegen_success_Ghash_register ()) (va_codegen_success_Store128_byte16_buffer
    (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 1) (va_op_reg_opr_reg 3) Secret)))))))))))
    (va_ttrue ()))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Compute_iv (va_mods:va_mods_t) (iv_b:buffer128) (iv_extra_b:buffer128)
  (iv:supported_iv_BE) (j0_b:buffer128) (hkeys_b:buffer128) : (va_quickCode unit
  (va_code_Compute_iv ())) =
  (qblock va_mods (fun (va_s:va_state) -> let (va_old_s:va_state) = va_s in let
    (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_old_s)) in va_QBind
    va_range1
    "***** PRECONDITION NOT MET AT line 547 column 8 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_qIf va_mods (Cmp_eq (va_op_cmp_reg 9) (va_const_cmp 12)) (qblock va_mods (fun
    (va_s:va_state) -> va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 548 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 0)
    (va_op_reg_opr_reg 4) Secret iv_extra_b 0) (fun (va_s:va_state) _ -> let (iv_BE:quad32) =
    va_get_vec 0 va_s in va_qAssertSquash va_range1
    "***** EXPRESSION PRECONDITIONS NOT MET WITHIN line 550 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    ((fun a_336 (s_337:(FStar.Seq.Base.seq a_336)) (i_338:Prims.nat) -> let (i_312:Prims.nat) =
    i_338 in Prims.b2t (Prims.op_LessThan i_312 (FStar.Seq.Base.length #a_336 s_337)))
    Vale.Def.Types_s.quad32 (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 6 va_s) iv_extra_b)) 0) (fun _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 550 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (iv_BE == FStar.Seq.Base.index #Vale.Def.Types_s.quad32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6 va_s)
    iv_extra_b)) 0) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 551 column 17 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vspltisw (va_op_vec_opr_vec 1) 1) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 552 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vsldoi (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) 12)
    (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 553 column 15 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Vsldoi (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 0) (va_op_vec_opr_vec 1) 4) (fun
    (va_s:va_state) _ -> va_qAssert va_range1
    "***** PRECONDITION NOT MET AT line 554 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_vec 0 va_s == Vale.AES.GCM_BE.set_to_one iv_BE) (let (j0:quad32) = va_get_vec 0 va_s in
    va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 556 column 31 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 0)
    (va_op_reg_opr_reg 3) Secret j0_b 0) (fun (va_s:va_state) _ -> let
    (va_arg44:Vale.Def.Types_s.quad32) = j0 in let (va_arg43:Vale.Def.Types_s.quad32) =
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_old_s)) in let (va_arg42:Vale.Def.Words_s.nat64) = va_get_reg 9 va_s
    in let (va_arg41:Vale.AES.GCM_BE_s.supported_iv_BE) = iv in let (va_arg40:(FStar.Seq.Base.seq
    Vale.Def.Types_s.quad32)) = Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 6 va_old_s) iv_extra_b) in let (va_arg39:(FStar.Seq.Base.seq
    Vale.Def.Types_s.quad32)) = Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 1 va_old_s) iv_b) in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 557 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_BE.lemma_compute_iv_easy va_arg39 va_arg40 va_arg41 va_arg42
    va_arg43 va_arg44) (va_QEmpty (())))))))))))) (qblock va_mods (fun (va_s:va_state) -> let
    (raw1:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = FStar.Seq.Base.append
    #Vale.Def.Types_s.quad32 (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128
    (va_get_mem_heaplet 1 va_old_s) iv_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6 va_old_s) iv_extra_b)) in let
    (raw2:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = Vale.Arch.Types.reverse_bytes_quad32_seq
    (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_old_s) iv_b) in let (raw_quads:(seq quad32))
    = va_if (va_get_reg 9 va_old_s > va_get_reg 6 va_old_s `op_Multiply` 128 `op_Division` 8) (fun
    _ -> raw1) (fun _ -> raw2) in let (va_arg57:Prims.nat) = va_get_reg 9 va_old_s in let
    (va_arg56:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = raw_quads in let
    (va_arg55:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6
    va_old_s) iv_extra_b) in let (va_arg54:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) =
    Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1
    va_old_s) iv_b) in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 562 column 32 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_BE.lemma_length_simplifier va_arg54 va_arg55 va_arg56 va_arg57)
    (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 564 column 9 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_blocks_auth iv_b iv_extra_b hkeys_b h_BE) (fun (va_s:va_state)
    (auth_quad_seq:(seq quad32)) -> let (y_mid:quad32) = va_get_vec 1 va_s in va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 567 column 13 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Move (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 9)) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 568 column 18 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_LoadImm64 (va_op_reg_opr_reg 7) 0) (va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 570 column 29 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Gcm_make_length_quad ()) (fun (va_s:va_state) _ -> let (length_quad:quad32) =
    va_get_vec 9 va_s in va_QBind va_range1
    "***** PRECONDITION NOT MET AT line 573 column 23 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Ghash_register hkeys_b h_BE y_mid) (fun (va_s:va_state) _ -> let (y_final:quad32) =
    va_get_vec 1 va_s in let (va_arg53:Vale.Def.Types_s.quad32) = length_quad in let
    (va_arg52:(FStar.Seq.Base.seq Vale.Def.Types_s.quad32)) = auth_quad_seq in let
    (va_arg51:Vale.Def.Types_s.quad32) = y_final in let (va_arg50:Vale.Def.Types_s.quad32) = y_mid
    in let (va_arg49:Vale.Def.Types_s.quad32) = Vale.Def.Words_s.Mkfour #Vale.Def.Types_s.nat32 0 0
    0 0 in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 576 column 27 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GHash_BE.lemma_hash_append2 h_BE va_arg49 va_arg50 va_arg51 va_arg52
    va_arg53) (let (va_arg48:Vale.Def.Types_s.quad32) = va_get_vec 1 va_s in let
    (va_arg47:Vale.Def.Types_s.quad32) = length_quad in let (va_arg46:(FStar.Seq.Base.seq
    Vale.Def.Types_s.quad32)) = auth_quad_seq in let (va_arg45:Vale.AES.GCM_BE_s.supported_iv_BE) =
    iv in va_qPURE va_range1
    "***** PRECONDITION NOT MET AT line 578 column 30 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (fun (_:unit) -> Vale.AES.GCM_BE.lemma_compute_iv_hard va_arg45 va_arg46 va_arg47 h_BE
    va_arg48) (va_QSeq va_range1
    "***** PRECONDITION NOT MET AT line 579 column 31 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_quick_Store128_byte16_buffer (va_op_heaplet_mem_heaplet 6) (va_op_vec_opr_vec 1)
    (va_op_reg_opr_reg 3) Secret j0_b 0) (va_QEmpty (()))))))))))))) (fun (va_s:va_state) va_g ->
    va_QEmpty (()))))


val va_lemma_Compute_iv : va_b0:va_code -> va_s0:va_state -> iv_b:buffer128 -> iv_extra_b:buffer128
  -> iv:supported_iv_BE -> j0_b:buffer128 -> hkeys_b:buffer128
  -> Ghost (va_state & va_fuel)
  (requires (va_require_total va_b0 (va_code_Compute_iv ()) va_s0 /\ va_get_ok va_s0 /\ (let
    (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_s0)) in
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1 va_s0) (va_get_reg 7 va_s0) iv_b
    (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128
    (va_get_mem_heaplet 6 va_s0) (va_get_reg 4 va_s0) iv_extra_b 1 (va_get_mem_layout va_s0) Secret
    /\ Vale.PPC64LE.Decls.validDstAddrs128 (va_get_mem_heaplet 6 va_s0) (va_get_reg 3 va_s0) j0_b 1
    (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0
    va_s0) (va_get_reg 5 va_s0) hkeys_b 3 (va_get_mem_layout va_s0) Secret /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 iv_b == va_get_reg 6 va_s0 /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 iv_extra_b == 1 /\ va_get_reg 7
    va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\ (va_mul_nat (va_get_reg 6 va_s0) (128
    `op_Division` 8) <= va_get_reg 9 va_s0 /\ va_get_reg 9 va_s0 < va_mul_nat (va_get_reg 6 va_s0)
    (128 `op_Division` 8) + 128 `op_Division` 8) /\ (0 < 8 `op_Multiply` va_get_reg 9 va_s0 /\ 8
    `op_Multiply` va_get_reg 9 va_s0 < pow2_64) /\ Vale.AES.GHash_BE.hkeys_reqs_priv
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0)
    hkeys_b)) h_BE /\ (let iv_raw_quads = FStar.Seq.Base.append #Vale.Def.Types_s.quad32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0)
    iv_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6
    va_s0) iv_extra_b)) in let (iv_bytes_BE:supported_iv_BE) = FStar.Seq.Base.slice
    #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 iv_raw_quads)) 0 (va_get_reg 9
    va_s0) in iv_bytes_BE == iv))))
  (ensures (fun (va_sM, va_fM) -> va_ensure_total va_b0 va_s0 va_sM va_fM /\ va_get_ok va_sM /\
    (let (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_s0)) in
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read j0_b 0
    (va_get_mem_heaplet 6 va_sM)) == Vale.AES.GCM_BE_s.compute_iv_BE h_BE iv /\
    Vale.PPC64LE.Decls.modifies_buffer128 j0_b (va_get_mem_heaplet 6 va_s0) (va_get_mem_heaplet 6
    va_sM)) /\ va_state_eq va_sM (va_update_mem_heaplet 6 va_sM (va_update_cr0 va_sM (va_update_vec
    14 va_sM (va_update_vec 13 va_sM (va_update_vec 12 va_sM (va_update_vec 11 va_sM (va_update_vec
    10 va_sM (va_update_vec 9 va_sM (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6
    va_sM (va_update_vec 5 va_sM (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2
    va_sM (va_update_vec 1 va_sM (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 8
    va_sM (va_update_reg 7 va_sM (va_update_reg 6 va_sM (va_update_ok va_sM (va_update_mem va_sM
    va_s0)))))))))))))))))))))))))
[@"opaque_to_smt"]
let va_lemma_Compute_iv va_b0 va_s0 iv_b iv_extra_b iv j0_b hkeys_b =
  let (va_mods:va_mods_t) = [va_Mod_mem_heaplet 6; va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13;
    va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 8; va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok; va_Mod_mem] in
  let va_qc = va_qcode_Compute_iv va_mods iv_b iv_extra_b iv j0_b hkeys_b in
  let (va_sM, va_fM, va_g) = va_wp_sound_code_norm (va_code_Compute_iv ()) va_qc va_s0 (fun va_s0
    va_sM va_g -> let () = va_g in label va_range1
    "***** POSTCONDITION NOT MET AT line 498 column 1 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (va_get_ok va_sM) /\ (let (h_BE:Vale.Def.Types_s.quad32) =
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2
    (va_get_mem_heaplet 0 va_s0)) in label va_range1
    "***** POSTCONDITION NOT MET AT line 542 column 88 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read j0_b 0
    (va_get_mem_heaplet 6 va_sM)) == Vale.AES.GCM_BE_s.compute_iv_BE h_BE iv) /\ label va_range1
    "***** POSTCONDITION NOT MET AT line 545 column 52 of file /home/gebner/everest/hacl-star/vale/code/crypto/aes/ppc64le/Vale.AES.PPC64LE.GCMencrypt.vaf *****"
    (Vale.PPC64LE.Decls.modifies_buffer128 j0_b (va_get_mem_heaplet 6 va_s0) (va_get_mem_heaplet 6
    va_sM)))) in
  assert_norm (va_qc.mods == va_mods);
  va_lemma_norm_mods ([va_Mod_mem_heaplet 6; va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec
    12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6;
    va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg
    10; va_Mod_reg 8; va_Mod_reg 7; va_Mod_reg 6; va_Mod_ok; va_Mod_mem]) va_sM va_s0;
  (va_sM, va_fM)

[@ va_qattr]
let va_wp_Compute_iv (iv_b:buffer128) (iv_extra_b:buffer128) (iv:supported_iv_BE) (j0_b:buffer128)
  (hkeys_b:buffer128) (va_s0:va_state) (va_k:(va_state -> unit -> Type0)) : Type0 =
  (va_get_ok va_s0 /\ (let (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_s0)) in
    Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 1 va_s0) (va_get_reg 7 va_s0) iv_b
    (va_get_reg 6 va_s0) (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128
    (va_get_mem_heaplet 6 va_s0) (va_get_reg 4 va_s0) iv_extra_b 1 (va_get_mem_layout va_s0) Secret
    /\ Vale.PPC64LE.Decls.validDstAddrs128 (va_get_mem_heaplet 6 va_s0) (va_get_reg 3 va_s0) j0_b 1
    (va_get_mem_layout va_s0) Secret /\ Vale.PPC64LE.Decls.validSrcAddrs128 (va_get_mem_heaplet 0
    va_s0) (va_get_reg 5 va_s0) hkeys_b 3 (va_get_mem_layout va_s0) Secret /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 iv_b == va_get_reg 6 va_s0 /\
    Vale.PPC64LE.Decls.buffer_length #Vale.PPC64LE.Memory.vuint128 iv_extra_b == 1 /\ va_get_reg 7
    va_s0 + 16 `op_Multiply` va_get_reg 6 va_s0 < pow2_64 /\ (va_mul_nat (va_get_reg 6 va_s0) (128
    `op_Division` 8) <= va_get_reg 9 va_s0 /\ va_get_reg 9 va_s0 < va_mul_nat (va_get_reg 6 va_s0)
    (128 `op_Division` 8) + 128 `op_Division` 8) /\ (0 < 8 `op_Multiply` va_get_reg 9 va_s0 /\ 8
    `op_Multiply` va_get_reg 9 va_s0 < pow2_64) /\ Vale.AES.GHash_BE.hkeys_reqs_priv
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 0 va_s0)
    hkeys_b)) h_BE /\ (let iv_raw_quads = FStar.Seq.Base.append #Vale.Def.Types_s.quad32
    (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 1 va_s0)
    iv_b)) (Vale.Arch.Types.reverse_bytes_quad32_seq (Vale.PPC64LE.Decls.s128 (va_get_mem_heaplet 6
    va_s0) iv_extra_b)) in let (iv_bytes_BE:supported_iv_BE) = FStar.Seq.Base.slice
    #Vale.Def.Words_s.nat8 (Vale.Def.Words.Seq_s.seq_nat32_to_seq_nat8_BE
    (Vale.Def.Words.Seq_s.seq_four_to_seq_BE #Vale.Def.Words_s.nat32 iv_raw_quads)) 0 (va_get_reg 9
    va_s0) in iv_bytes_BE == iv)) /\ (forall (va_x_mem:vale_heap) (va_x_r6:nat64) (va_x_r7:nat64)
    (va_x_r8:nat64) (va_x_r10:nat64) (va_x_v0:quad32) (va_x_v1:quad32) (va_x_v2:quad32)
    (va_x_v3:quad32) (va_x_v4:quad32) (va_x_v5:quad32) (va_x_v6:quad32) (va_x_v7:quad32)
    (va_x_v8:quad32) (va_x_v9:quad32) (va_x_v10:quad32) (va_x_v11:quad32) (va_x_v12:quad32)
    (va_x_v13:quad32) (va_x_v14:quad32) (va_x_cr0:cr0_t) (va_x_heap6:vale_heap) . let va_sM =
    va_upd_mem_heaplet 6 va_x_heap6 (va_upd_cr0 va_x_cr0 (va_upd_vec 14 va_x_v14 (va_upd_vec 13
    va_x_v13 (va_upd_vec 12 va_x_v12 (va_upd_vec 11 va_x_v11 (va_upd_vec 10 va_x_v10 (va_upd_vec 9
    va_x_v9 (va_upd_vec 8 va_x_v8 (va_upd_vec 7 va_x_v7 (va_upd_vec 6 va_x_v6 (va_upd_vec 5 va_x_v5
    (va_upd_vec 4 va_x_v4 (va_upd_vec 3 va_x_v3 (va_upd_vec 2 va_x_v2 (va_upd_vec 1 va_x_v1
    (va_upd_vec 0 va_x_v0 (va_upd_reg 10 va_x_r10 (va_upd_reg 8 va_x_r8 (va_upd_reg 7 va_x_r7
    (va_upd_reg 6 va_x_r6 (va_upd_mem va_x_mem va_s0))))))))))))))))))))) in va_get_ok va_sM /\
    (let (h_BE:Vale.Def.Types_s.quad32) = Vale.Def.Types_s.reverse_bytes_quad32
    (Vale.PPC64LE.Decls.buffer128_read hkeys_b 2 (va_get_mem_heaplet 0 va_s0)) in
    Vale.Def.Types_s.reverse_bytes_quad32 (Vale.PPC64LE.Decls.buffer128_read j0_b 0
    (va_get_mem_heaplet 6 va_sM)) == Vale.AES.GCM_BE_s.compute_iv_BE h_BE iv /\
    Vale.PPC64LE.Decls.modifies_buffer128 j0_b (va_get_mem_heaplet 6 va_s0) (va_get_mem_heaplet 6
    va_sM)) ==> va_k va_sM (())))


val va_wpProof_Compute_iv : iv_b:buffer128 -> iv_extra_b:buffer128 -> iv:supported_iv_BE ->
  j0_b:buffer128 -> hkeys_b:buffer128 -> va_s0:va_state -> va_k:(va_state -> unit -> Type0)
  -> Ghost (va_state & va_fuel & unit)
  (requires (va_t_require va_s0 /\ va_wp_Compute_iv iv_b iv_extra_b iv j0_b hkeys_b va_s0 va_k))
  (ensures (fun (va_sM, va_f0, va_g) -> va_t_ensure (va_code_Compute_iv ()) ([va_Mod_mem_heaplet 6;
    va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10;
    va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec
    3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg 10; va_Mod_reg 8; va_Mod_reg 7;
    va_Mod_reg 6; va_Mod_mem]) va_s0 va_k ((va_sM, va_f0, va_g))))
[@"opaque_to_smt"]
let va_wpProof_Compute_iv iv_b iv_extra_b iv j0_b hkeys_b va_s0 va_k =
  let (va_sM, va_f0) = va_lemma_Compute_iv (va_code_Compute_iv ()) va_s0 iv_b iv_extra_b iv j0_b
    hkeys_b in
  va_lemma_upd_update va_sM;
  assert (va_state_eq va_sM (va_update_mem_heaplet 6 va_sM (va_update_cr0 va_sM (va_update_vec 14
    va_sM (va_update_vec 13 va_sM (va_update_vec 12 va_sM (va_update_vec 11 va_sM (va_update_vec 10
    va_sM (va_update_vec 9 va_sM (va_update_vec 8 va_sM (va_update_vec 7 va_sM (va_update_vec 6
    va_sM (va_update_vec 5 va_sM (va_update_vec 4 va_sM (va_update_vec 3 va_sM (va_update_vec 2
    va_sM (va_update_vec 1 va_sM (va_update_vec 0 va_sM (va_update_reg 10 va_sM (va_update_reg 8
    va_sM (va_update_reg 7 va_sM (va_update_reg 6 va_sM (va_update_ok va_sM (va_update_mem va_sM
    va_s0))))))))))))))))))))))));
  va_lemma_norm_mods ([va_Mod_mem_heaplet 6; va_Mod_cr0; va_Mod_vec 14; va_Mod_vec 13; va_Mod_vec
    12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7; va_Mod_vec 6;
    va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec 0; va_Mod_reg
    10; va_Mod_reg 8; va_Mod_reg 7; va_Mod_reg 6; va_Mod_mem]) va_sM va_s0;
  let va_g = () in
  (va_sM, va_f0, va_g)

[@ "opaque_to_smt" va_qattr]
let va_quick_Compute_iv (iv_b:buffer128) (iv_extra_b:buffer128) (iv:supported_iv_BE)
  (j0_b:buffer128) (hkeys_b:buffer128) : (va_quickCode unit (va_code_Compute_iv ())) =
  (va_QProc (va_code_Compute_iv ()) ([va_Mod_mem_heaplet 6; va_Mod_cr0; va_Mod_vec 14; va_Mod_vec
    13; va_Mod_vec 12; va_Mod_vec 11; va_Mod_vec 10; va_Mod_vec 9; va_Mod_vec 8; va_Mod_vec 7;
    va_Mod_vec 6; va_Mod_vec 5; va_Mod_vec 4; va_Mod_vec 3; va_Mod_vec 2; va_Mod_vec 1; va_Mod_vec
    0; va_Mod_reg 10; va_Mod_reg 8; va_Mod_reg 7; va_Mod_reg 6; va_Mod_mem]) (va_wp_Compute_iv iv_b
    iv_extra_b iv j0_b hkeys_b) (va_wpProof_Compute_iv iv_b iv_extra_b iv j0_b hkeys_b))
//--
//-- Gcm_blocks
#push-options "--z3rlimit 600"

val va_code_Gcm_blocks : alg:algorithm -> Tot va_code
[@ "opaque_to_smt" va_qattr]
let va_code_Gcm_blocks alg =
  (va_Block (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 5)
    (va_op_reg_opr_reg 25) (11 `op_Multiply` 8) Secret) (va_CCons (va_code_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25) (0 `op_Multiply` 8)
    Secret) (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 25) (6 `op_Multiply` 8) Secret) (va_CCons (va_code_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25) (7 `op_Multiply` 8)
    Secret) (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 9)
    (va_op_reg_opr_reg 25) (8 `op_Multiply` 8) Secret) (va_CCons (va_code_Gcm_blocks_auth ())
    (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 10)
    (va_op_reg_opr_reg 25) (9 `op_Multiply` 8) Secret) (va_CCons (va_code_Load128_byte16_buffer
    (va_op_heaplet_mem_heaplet 2) (va_op_vec_opr_vec 7) (va_op_reg_opr_reg 10) Public) (va_CCons
    (va_code_Vmr (va_op_vec_opr_vec 21) (va_op_vec_opr_vec 7)) (va_CCons (va_code_Load_one_lsb
    (va_op_vec_opr_vec 10)) (va_CCons (va_code_Vadduwm (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 7)
    (va_op_vec_opr_vec 10)) (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3)
    (va_op_reg_opr_reg 3) (va_op_reg_opr_reg 25) (1 `op_Multiply` 8) Secret) (va_CCons
    (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25)
    (2 `op_Multiply` 8) Secret) (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3)
    (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25) (3 `op_Multiply` 8) Secret) (va_CCons
    (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25)
    (10 `op_Multiply` 8) Secret) (va_CCons (va_code_Gcm_blocks128 alg) (va_CCons (va_code_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25) (3 `op_Multiply` 8)
    Secret) (va_CCons (va_code_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7) 4) (va_CCons
    (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25)
    (5 `op_Multiply` 8) Secret) (va_CCons (va_IfElse (va_cmp_gt (va_op_cmp_reg 6) (va_op_cmp_reg
    7)) (va_Block (va_CCons (va_code_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 3)
    (va_op_reg_opr_reg 25) (4 `op_Multiply` 8) Secret) (va_CCons (va_code_LoadImm64
    (va_op_reg_opr_reg 10) 15) (va_CCons (va_code_And (va_op_reg_opr_reg 8) (va_op_reg_opr_reg 6)
    (va_op_reg_opr_reg 10)) (va_CCons (va_code_Gcm_extra_bytes alg) (va_CCons (va_Block (va_CNil
    ())) (va_CNil ()))))))) (va_Block (va_CNil ()))) (va_CCons (va_code_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25) (8 `op_Multiply` 8)
    Secret) (va_CCons (va_code_Gcm_make_length_quad ()) (va_CCons (va_code_Ghash_register ())
    (va_CCons (va_code_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 21)) (va_CCons
    (va_code_Gctr_register alg) (va_CCons (va_Block (va_CNil ())) (va_CNil
    ()))))))))))))))))))))))))))))

val va_codegen_success_Gcm_blocks : alg:algorithm -> Tot va_pbool
[@ "opaque_to_smt" va_qattr]
let va_codegen_success_Gcm_blocks alg =
  (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 5)
    (va_op_reg_opr_reg 25) (11 `op_Multiply` 8) Secret) (va_pbool_and (va_codegen_success_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25) (0 `op_Multiply` 8)
    Secret) (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3)
    (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25) (6 `op_Multiply` 8) Secret) (va_pbool_and
    (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6)
    (va_op_reg_opr_reg 25) (7 `op_Multiply` 8) Secret) (va_pbool_and (va_codegen_success_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 9) (va_op_reg_opr_reg 25) (8 `op_Multiply` 8)
    Secret) (va_pbool_and (va_codegen_success_Gcm_blocks_auth ()) (va_pbool_and
    (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 10)
    (va_op_reg_opr_reg 25) (9 `op_Multiply` 8) Secret) (va_pbool_and
    (va_codegen_success_Load128_byte16_buffer (va_op_heaplet_mem_heaplet 2) (va_op_vec_opr_vec 7)
    (va_op_reg_opr_reg 10) Public) (va_pbool_and (va_codegen_success_Vmr (va_op_vec_opr_vec 21)
    (va_op_vec_opr_vec 7)) (va_pbool_and (va_codegen_success_Load_one_lsb (va_op_vec_opr_vec 10))
    (va_pbool_and (va_codegen_success_Vadduwm (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 7)
    (va_op_vec_opr_vec 10)) (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet
    3) (va_op_reg_opr_reg 3) (va_op_reg_opr_reg 25) (1 `op_Multiply` 8) Secret) (va_pbool_and
    (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 25) (2 `op_Multiply` 8) Secret) (va_pbool_and (va_codegen_success_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 25) (3 `op_Multiply` 8)
    Secret) (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3)
    (va_op_reg_opr_reg 4) (va_op_reg_opr_reg 25) (10 `op_Multiply` 8) Secret) (va_pbool_and
    (va_codegen_success_Gcm_blocks128 alg) (va_pbool_and (va_codegen_success_MemLoad64
    (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 25) (3 `op_Multiply` 8)
    Secret) (va_pbool_and (va_codegen_success_Sl64Imm (va_op_reg_opr_reg 7) (va_op_reg_opr_reg 7)
    4) (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg
    6) (va_op_reg_opr_reg 25) (5 `op_Multiply` 8) Secret) (va_pbool_and (va_pbool_and
    (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 3)
    (va_op_reg_opr_reg 25) (4 `op_Multiply` 8) Secret) (va_pbool_and (va_codegen_success_LoadImm64
    (va_op_reg_opr_reg 10) 15) (va_pbool_and (va_codegen_success_And (va_op_reg_opr_reg 8)
    (va_op_reg_opr_reg 6) (va_op_reg_opr_reg 10)) (va_codegen_success_Gcm_extra_bytes alg))))
    (va_pbool_and (va_codegen_success_MemLoad64 (va_op_heaplet_mem_heaplet 3) (va_op_reg_opr_reg 7)
    (va_op_reg_opr_reg 25) (8 `op_Multiply` 8) Secret) (va_pbool_and
    (va_codegen_success_Gcm_make_length_quad ()) (va_pbool_and (va_codegen_success_Ghash_register
    ()) (va_pbool_and (va_codegen_success_Vmr (va_op_vec_opr_vec 7) (va_op_vec_opr_vec 21))
    (va_pbool_and (va_codegen_success_Gctr_register alg) (va_ttrue ()))))))))))))))))))))))))))

[@ "opaque_to_smt" va_qattr]
let va_qcode_Gcm_blocks (va_mods:va_mods_t) (alg:algorithm) (auth_b:buffer128) (abytes_b:buffer128)
  (in128_b:buffer128) (out128_b:buffer128) (inout_b:buffer128) (iv_b:buffer128) (key:(seq nat32))
  (round_keys:(seq quad32)) (keys_b:buffer128) (hkeys_b:buffer128) (gcm_struct_b:buffer64) :
val va_qcode_Gcm_blocks
      (va_mods: va_mods_t)
      (alg: algorithm)
      (auth_b abytes_b in128_b out128_b inout_b iv_b: buffer128)
      (key: (seq nat32))
      (round_keys: (seq quad32))
      (keys_b hkeys_b: buffer128)
      (gcm_struct_b: buffer64)
    : (va_quickCode unit (va_code_Gcm_blocks alg))

    va_mods: Vale.PPC64LE.QuickCode.va_mods_t ->
    alg: Vale.AES.AES_common_s.algorithm ->
    auth_b: Vale.PPC64LE.Memory.buffer128 ->
    abytes_b: Vale.PPC64LE.Memory.buffer128 ->
    in128_b: Vale.PPC64LE.Memory.buffer128 ->
    out128_b: Vale.PPC64LE.Memory.buffer128 ->
    inout_b: Vale.PPC64LE.Memory.buffer128 ->
    iv_b: Vale.PPC64LE.Memory.buffer128 ->
    key: FStar.Seq.Base.seq Vale.PPC64LE.Memory.nat32 ->
    round_keys: FStar.Seq.Base.seq Vale.PPC64LE.Memory.quad32 ->
    keys_b: Vale.PPC64LE.Memory.buffer128 ->
    hkeys_b: Vale.PPC64LE.Memory.buffer128 ->
    gcm_struct_b: Vale.PPC64LE.Memory.buffer64
  -> Vale.PPC64LE.QuickCode.va_quickCode Prims.unit
      (Vale.AES.PPC64LE.GCMencrypt.va_code_Gcm_blocks alg)