// File: /workspace/github_cpp_makefile_star2_O3/CMU-SAFARI[P]ramulator/src/LPDDR3.cpp
// Function: ramulator::LPDDR3::LPDDR3(ramulator::LPDDR3::Org, ramulator::LPDDR3::Speed)
LPDDR3::LPDDR3(Org org, Speed speed)
    : org_entry(org_table[int(org)]),
    speed_entry(speed_table[int(speed)]),
    read_latency(speed_entry.nCL + speed_entry.nDQSCK + speed_entry.nBL)
{
    init_speed();
    init_prereq();
    init_rowhit(); // SAUGATA: added row hit function
    init_rowopen();
    init_lambda();
    init_timing();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
leaq 0x35c44(%rip), %rsi     # 0x1541d1
leaq 0x35c40(%rip), %rdx     # 0x1541d4
callq 0x175a0
leaq 0x20(%rbx), %r14
leaq 0x30(%rbx), %rax
movq %rax, 0x20(%rbx)
leaq 0x35c29(%rip), %rsi     # 0x1541d5
leaq 0x35c25(%rip), %rdx     # 0x1541d8
movq %r14, %rdi
callq 0x175a0
leaq 0x40(%rbx), %r14
leaq 0x50(%rbx), %rax
movq %rax, 0x40(%rbx)
leaq 0x3a837(%rip), %rsi     # 0x158e05
leaq 0x3a833(%rip), %rdx     # 0x158e08
movq %r14, %rdi
callq 0x175a0
leaq 0x60(%rbx), %r14
leaq 0x70(%rbx), %rax
movq %rax, 0x60(%rbx)
leaq 0x35be9(%rip), %rsi     # 0x1541d9
leaq 0x35be4(%rip), %rdx     # 0x1541db
movq %r14, %rdi
callq 0x175a0
leaq 0x80(%rbx), %r14
leaq 0x90(%rbx), %rax
movq %rax, 0x80(%rbx)
leaq 0x2c5c7(%rip), %rsi     # 0x14abe2
leaq 0x2c5c2(%rip), %rdx     # 0x14abe4
movq %r14, %rdi
callq 0x175a0
leaq 0xa0(%rbx), %r14
leaq 0xb0(%rbx), %rax
movq %rax, 0xa0(%rbx)
leaq 0x35b96(%rip), %rsi     # 0x1541dc
leaq 0x35b92(%rip), %rdx     # 0x1541df
movq %r14, %rdi
callq 0x175a0
leaq 0xc0(%rbx), %r14
leaq 0xd0(%rbx), %rax
movq %rax, 0xc0(%rbx)
leaq 0x35b6f(%rip), %rsi     # 0x1541e0
leaq 0x35b6b(%rip), %rdx     # 0x1541e3
movq %r14, %rdi
callq 0x175a0
leaq 0xe0(%rbx), %r14
leaq 0xf0(%rbx), %rax
movq %rax, 0xe0(%rbx)
leaq 0x3ec8b(%rip), %rsi     # 0x15d327
leaq 0x3ec87(%rip), %rdx     # 0x15d32a
movq %r14, %rdi
callq 0x175a0
leaq 0x100(%rbx), %r14
leaq 0x110(%rbx), %rax
movq %rax, 0x100(%rbx)
leaq 0x3929d(%rip), %rsi     # 0x157964
leaq 0x3929b(%rip), %rdx     # 0x157969
movq %r14, %rdi
callq 0x175a0
leaq 0x120(%rbx), %r14
leaq 0x130(%rbx), %rax
movq %rax, 0x120(%rbx)
leaq 0x3a717(%rip), %rsi     # 0x158e09
leaq 0x3a712(%rip), %rdx     # 0x158e0b
movq %r14, %rdi
callq 0x175a0
leaq 0x140(%rbx), %r14
leaq 0x150(%rbx), %rax
movq %rax, 0x140(%rbx)
leaq 0x35acb(%rip), %rsi     # 0x1541e8
leaq 0x35ac7(%rip), %rdx     # 0x1541eb
movq %r14, %rdi
callq 0x175a0
leaq 0x160(%rbx), %r14
leaq 0x170(%rbx), %rax
movq %rax, 0x160(%rbx)
leaq 0x3a6c4(%rip), %rsi     # 0x158e0c
leaq 0x3a6c1(%rip), %rdx     # 0x158e10
movq %r14, %rdi
callq 0x175a0
leaq 0x180(%rbx), %r14
leaq 0x190(%rbx), %rax
movq %rax, 0x180(%rbx)
leaq 0x3a69e(%rip), %rsi     # 0x158e11
leaq 0x3a69c(%rip), %rdx     # 0x158e16
movq %r14, %rdi
callq 0x175a0
leaq 0x1a0(%rbx), %r14
movups 0x3a840(%rip), %xmm0    # 0x158fd0
movups %xmm0, 0x1c0(%rbx)
movups 0x3a822(%rip), %xmm0    # 0x158fc0
movups %xmm0, 0x1b0(%rbx)
movups 0x3a804(%rip), %xmm0    # 0x158fb0
movups %xmm0, 0x1a0(%rbx)
movl $0x1, 0x1d0(%rbx)
movups 0x3a820(%rip), %xmm0    # 0x158fe4
movups %xmm0, 0x1d4(%rbx)
movl $0x6, 0x1e4(%rbx)
movups 0x3940c(%rip), %xmm0    # 0x157be8
movups %xmm0, 0x1e8(%rbx)
movq $0xb, 0x1f8(%rbx)
leaq 0x200(%rbx), %rdi
leaq 0x2898(%rbx), %r12
movl $0x2698, %edx           # imm = 0x2698
xorl %esi, %esi
callq 0xb1d0
leaq 0x3a7e9(%rip), %rsi     # 0x158ff8
movl $0x118, %edx            # imm = 0x118
movq %r12, %rdi
callq 0xb270
movslq %r15d, %rax
leaq (%rax,%rax,8), %rcx
leaq (%rcx,%rcx,2), %rcx
addq %rax, %rcx
movups 0x2898(%rbx,%rcx), %xmm0
movups 0x28a4(%rbx,%rcx), %xmm1
movups %xmm0, 0x29b0(%rbx)
movups %xmm1, 0x29bc(%rbx)
movabsq $0x4000000008, %rax     # imm = 0x4000000008
movq %rax, 0x29cc(%rbx)
leaq 0x29d8(%rbx), %rdi
leaq 0x3a8a9(%rip), %rsi     # 0x159110
movl $0x1e0, %edx            # imm = 0x1E0
callq 0xb270
leaq 0x2bb8(%rbx), %rdi
movslq %ebp, %rax
imulq $0x78, %rax, %rax
leaq (%rbx,%rax), %rsi
addq $0x29d8, %rsi           # imm = 0x29D8
movl $0xf, %ecx
rep  movsq (%rsi), %es:(%rdi)
movl 0x2bdc(%rbx), %eax
addl 0x2be0(%rbx), %eax
addl 0x2bd0(%rbx), %eax
movl %eax, 0x2c30(%rbx)
movq %rbx, %rdi
callq 0x11ea44
movq %rbx, %rdi
callq 0x11eb34
movq %rbx, %rdi
callq 0x11eda4
movq %rbx, %rdi
callq 0x11ee2c
movq %rbx, %rdi
callq 0x11eeb4
movq %rbx, %rdi
callq 0x11f324
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
jmp 0x11e8ff
movq %rax, %r15
addq $-0x10, %r14
movq -0x10(%r14), %rdi
cmpq %rdi, %r14
je 0x11e91a
movq (%r14), %rsi
incq %rsi
callq 0xb2f0
leaq -0x20(%r14), %rax
addq $-0x10, %r14
cmpq %rbx, %r14
movq %rax, %r14
jne 0x11e906
jmp 0x11ea2e
movq %rax, %r15
leaq 0x2878(%rbx), %r12
xorl %r13d, %r13d
movq 0x2888(%rbx,%r13), %rax
testq %rax, %rax
je 0x11e957
leaq (%r12,%r13), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x20, %r13
cmpq $-0x820, %r13           # imm = 0xF7E0
jne 0x11e93c
movl $0x2070, %r12d          # imm = 0x2070
movq -0x10(%rbx,%r12), %rdi
testq %rdi, %rdi
je 0x11e980
movq (%rbx,%r12), %rsi
subq %rdi, %rsi
callq 0xb2f0
addq $-0x18, %r12
cmpq $0x1a58, %r12           # imm = 0x1A58
jne 0x11e96a
leaq 0x1a40(%rbx), %r12
xorl %r13d, %r13d
movq 0x1a50(%rbx,%r13), %rax
testq %rax, %rax
je 0x11e9b2
leaq (%r12,%r13), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x20, %r13
cmpq $-0x820, %r13           # imm = 0xF7E0
jne 0x11e997
leaq 0x1220(%rbx), %r12
xorl %r13d, %r13d
movq 0x1230(%rbx,%r13), %rax
testq %rax, %rax
je 0x11e9e4
leaq (%r12,%r13), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x20, %r13
cmpq $-0x820, %r13           # imm = 0xF7E0
jne 0x11e9c9
leaq 0xa00(%rbx), %r12
xorl %r13d, %r13d
movq 0xa10(%rbx,%r13), %rax
testq %rax, %rax
je 0x11ea16
leaq (%r12,%r13), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x20, %r13
cmpq $-0x820, %r13           # imm = 0xF7E0
jne 0x11e9fb
movq %r14, %rdi
movq %rbx, %rsi
callq 0xbec1
movq %r15, %rdi
callq 0xb510
jmp 0x11ea3c
jmp 0x11ea3c
jmp 0x11ea3c
movq %rax, %rdi
callq 0x171a3