// File: /workspace/github_c_makefile_star2_O3/OpenKMIP[P]libkmip/src/kmip.c
// Function: kmip_decode_bool
int
kmip_decode_bool(KMIP *ctx, enum tag t, bool32 *value)
{
    CHECK_BUFFER_FULL(ctx, 16);
    
    int32 tag_type = 0;
    uint32 length = 0;
    int32 padding = 0;
    
    kmip_decode_int32_be(ctx, &tag_type);
    CHECK_TAG_TYPE(ctx, tag_type, t, KMIP_TYPE_BOOLEAN);
    
    kmip_decode_length(ctx, &length);
    CHECK_LENGTH(ctx, length, 8);
    
    kmip_decode_int32_be(ctx, &padding);
    CHECK_PADDING(ctx, padding);
    
    kmip_decode_int32_be(ctx, value);
    CHECK_BOOLEAN(ctx, *value);
    
    return(KMIP_OK);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq 0x10(%rdi), %rax
subq 0x8(%rdi), %rax
addq (%rdi), %rax
cmpq $0xf, %rax
ja 0x106dd
leaq 0x38(%rbx), %rdi
xorl %r14d, %r14d
cmpl $0x0, 0x64(%rdi,%r14)
je 0x10770
addq $0x68, %r14
cmpq $0x820, %r14            # imm = 0x820
jne 0x106bf
jmp 0x10797
movq %rdx, %r14
movl %esi, %ebp
xorl %eax, %eax
leaq 0x14(%rsp), %r15
movl %eax, (%r15)
movl %eax, 0x10(%rsp)
movl %eax, 0xc(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x6a10
movl (%r15), %eax
movl %eax, %ecx
sarl $0x8, %ecx
cmpl %ebp, %ecx
jne 0x107a1
cmpb $0x6, %al
jne 0x107f0
leaq 0x10(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x64b0
cmpl $0x8, (%r15)
jne 0x1083f
leaq 0xc(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x6a10
cmpl $0x0, (%r15)
je 0x1088b
leaq 0x38(%rbx), %rdi
xorl %r14d, %r14d
cmpl $0x0, 0x64(%rdi,%r14)
je 0x108b9
addq $0x68, %r14
cmpq $0x820, %r14            # imm = 0x820
jne 0x10752
jmp 0x108e0
addq %r14, %rdi
movq %rdi, 0x860(%rbx)
leaq 0xe71b(%rip), %rsi      # 0x1ee9c
movl $0x63, %edx
callq 0x66f0
movl $0x218a, 0x9c(%rbx,%r14) # imm = 0x218A
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
jmp 0x108e5
leaq 0x38(%rbx), %rdi
xorl %r14d, %r14d
cmpl $0x0, 0x64(%rdi,%r14)
je 0x107bf
addq $0x68, %r14
cmpq $0x820, %r14            # imm = 0x820
jne 0x107a8
jmp 0x107e6
addq %r14, %rdi
movq %rdi, 0x860(%rbx)
leaq 0xe6cc(%rip), %rsi      # 0x1ee9c
movl $0x63, %edx
callq 0x66f0
movl $0x2191, 0x9c(%rbx,%r14) # imm = 0x2191
movl $0xfffffffc, %eax       # imm = 0xFFFFFFFC
jmp 0x108e5
leaq 0x38(%rbx), %rdi
xorl %r14d, %r14d
cmpl $0x0, 0x64(%rdi,%r14)
je 0x1080e
addq $0x68, %r14
cmpq $0x820, %r14            # imm = 0x820
jne 0x107f7
jmp 0x10835
addq %r14, %rdi
movq %rdi, 0x860(%rbx)
leaq 0xe67d(%rip), %rsi      # 0x1ee9c
movl $0x63, %edx
callq 0x66f0
movl $0x2191, 0x9c(%rbx,%r14) # imm = 0x2191
movl $0xfffffffb, %eax       # imm = 0xFFFFFFFB
jmp 0x108e5
leaq 0x38(%rbx), %rdi
xorl %r14d, %r14d
cmpl $0x0, 0x64(%rdi,%r14)
je 0x1085d
addq $0x68, %r14
cmpq $0x820, %r14            # imm = 0x820
jne 0x10846
jmp 0x10884
addq %r14, %rdi
movq %rdi, 0x860(%rbx)
leaq 0xe62e(%rip), %rsi      # 0x1ee9c
movl $0x63, %edx
callq 0x66f0
movl $0x2194, 0x9c(%rbx,%r14) # imm = 0x2194
movl $0xfffffffa, %eax       # imm = 0xFFFFFFFA
jmp 0x108e5
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6a10
xorl %eax, %eax
cmpl $0x2, (%r14)
jb 0x108e5
leaq 0xfd3e(%rip), %rsi      # 0x205e3
movq %rbx, %rdi
movl $0x219a, %edx           # imm = 0x219A
callq 0x6de0
movl $0xfffffff8, %eax       # imm = 0xFFFFFFF8
jmp 0x108e5
addq %r14, %rdi
movq %rdi, 0x860(%rbx)
leaq 0xe5d2(%rip), %rsi      # 0x1ee9c
movl $0x63, %edx
callq 0x66f0
movl $0x2197, 0x9c(%rbx,%r14) # imm = 0x2197
movl $0xfffffff9, %eax       # imm = 0xFFFFFFF9
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq