// File: /workspace/github_c_makefile_star2_O3/wjmelements[P]evm/tst/evm.c
// Function: test_sstore_gauntlet
void test_sstore_gauntlet() {
    evmInit();

    // 5f5f5560015f5560025f555f5f5560015f55600160015560026001555f60015500
    op_t program[] = {
        PUSH0, PUSH0, SSTORE,
        PUSH1, 0x01, PUSH0, SSTORE,
        PUSH1, 0x02, PUSH0, SSTORE,
        PUSH0, PUSH0, SSTORE,
        PUSH1, 0x01, PUSH0, SSTORE,
        PUSH1, 0x01, PUSH1, 0x01, SSTORE,
        PUSH1, 0x02, PUSH1, 0x01, SSTORE,
        PUSH0, PUSH1, 0x01, SSTORE,
        STOP,
    };
    address_t from = AddressFromHex42("0x4a6f6B9fF1fc974096f9063a45Fd12bD5B928AD1");
    uint64_t gas = 120461;
    val_t value;
    data_t input;
    input.content = program;
    input.size = sizeof(program);

    result_t result = txCreate(from, gas, value, input);
    evmFinalize();
    assert(UPPER(UPPER(result.status)) == 0);
    assert(LOWER(UPPER(result.status)) == 0x80d9b122);
    assert(UPPER(LOWER(result.status)) == 0xdc3a16fdc41f96cf);
    assert(LOWER(LOWER(result.status)) == 0x010ffe7e38d227c3);
    assert(result.returnData.size == 0);
    assert(result.gasRemaining == 25853);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
xorl %eax, %eax
callq 0xca4d
movaps 0x129f4(%rip), %xmm0    # 0x18870
movaps %xmm0, 0x40(%rsp)
movaps 0x129d8(%rip), %xmm0    # 0x18860
movaps %xmm0, 0x30(%rsp)
movb $0x0, 0x50(%rsp)
movq $-0x2, %r14
leaq 0x18(%rsp), %r15
leaq 0xe1cb(%rip), %r12      # 0x14070
movq 0x1814c(%rip), %r13     # 0x1dff8
leaq 0x1122a(%rip), %rbx     # 0x170dd
movzbl 0x4(%r14,%r12), %ecx
leal -0x30(%rcx), %ebp
cmpb $0xa, %bpl
jb 0x5eda
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x5ece
addb $-0x57, %cl
jmp 0x5ed8
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x5f18
addb $-0x37, %cl
movl %ecx, %ebp
movzbl 0x5(%r14,%r12), %ecx
leal -0x30(%rcx), %eax
cmpb $0xa, %al
jb 0x5eff
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x5ef3
addb $-0x57, %cl
jmp 0x5efd
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x5f2d
addb $-0x37, %cl
movl %ecx, %eax
shlb $0x4, %bpl
addb %al, %bpl
movb %bpl, (%r15)
addq $0x2, %r14
incq %r15
cmpq $0x26, %r14
jb 0x5eb3
jmp 0x5f41
movq (%r13), %rdi
movq %rbx, %rsi
movl %ecx, %edx
xorl %eax, %eax
callq 0x30a0
movb $-0x1, %bpl
jmp 0x5eda
movq (%r13), %rdi
movq %rbx, %rsi
movl %ecx, %edx
xorl %eax, %eax
callq 0x30a0
movb $-0x1, %al
jmp 0x5eff
movl 0x28(%rsp), %eax
movl %eax, 0x10(%rsp)
movups 0x18(%rsp), %xmm0
movups %xmm0, (%rsp)
leaq 0x58(%rsp), %rbx
leaq 0x9c(%rsp), %rdx
leaq 0x30(%rsp), %r8
movl $0x1d68d, %esi          # imm = 0x1D68D
movl $0x21, %ecx
movq %rbx, %rdi
callq 0xd683
xorl %eax, %eax
callq 0xcd49
cmpq $0x0, 0x10(%rbx)
jne 0x5fed
movl $0x80d9b122, %eax       # imm = 0x80D9B122
cmpq %rax, 0x70(%rsp)
jne 0x600c
movabsq $-0x23c5e9023be06931, %rax # imm = 0xDC3A16FDC41F96CF
cmpq %rax, 0x78(%rsp)
jne 0x602b
movabsq $0x10ffe7e38d227c3, %rax # imm = 0x10FFE7E38D227C3
cmpq %rax, 0x80(%rsp)
jne 0x604a
cmpq $0x0, 0x58(%rsp)
jne 0x6069
cmpq $0x64fd, 0x88(%rsp) # imm = 0x64FD
jne 0x6088
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xe0a7(%rip), %rdi      # 0x1409b
leaq 0xe0c1(%rip), %rsi      # 0x140bc
leaq 0xe718(%rip), %rcx      # 0x1471a
movl $0x357, %edx            # imm = 0x357
callq 0x3040
leaq 0xe0c4(%rip), %rdi      # 0x140d7
leaq 0xe0a2(%rip), %rsi      # 0x140bc
leaq 0xe6f9(%rip), %rcx      # 0x1471a
movl $0x358, %edx            # imm = 0x358
callq 0x3040
leaq 0xe0cf(%rip), %rdi      # 0x14101
leaq 0xe083(%rip), %rsi      # 0x140bc
leaq 0xe6da(%rip), %rcx      # 0x1471a
movl $0x359, %edx            # imm = 0x359
callq 0x3040
leaq 0xe0e2(%rip), %rdi      # 0x14133
leaq 0xe064(%rip), %rsi      # 0x140bc
leaq 0xe6bb(%rip), %rcx      # 0x1471a
movl $0x35a, %edx            # imm = 0x35A
callq 0x3040
leaq 0xe0f5(%rip), %rdi      # 0x14165
leaq 0xe045(%rip), %rsi      # 0x140bc
leaq 0xe69c(%rip), %rcx      # 0x1471a
movl $0x35b, %edx            # imm = 0x35B
callq 0x3040
leaq 0xe6a7(%rip), %rdi      # 0x14736
leaq 0xe026(%rip), %rsi      # 0x140bc
leaq 0xe67d(%rip), %rcx      # 0x1471a
movl $0x35c, %edx            # imm = 0x35C
callq 0x3040