// File: /workspace/github_cpp_makefile_star2_O3/UTSASRG[P]Guarder/./bibopheap.hh
// Function: BibopHeap::BibopObjCache::initialize(unsigned long, unsigned long, unsigned long*, BibopHeap::BibopFreeCache*, unsigned int)
void initialize(uintptr_t ustartaddr, uintptr_t uendaddr, uintptr_t * objectCache,
							BibopFreeCache * freeCache, unsigned shiftBits) {
					unsigned i;

          // Initialize each of the cache region object
          // counters to indicate an uninitialized object cache
          for(i = 0; i < NUM_CACHE_REGIONS; i++) {
              _regionCounters[i] = UNINITIALIZED_CACHE_REGION;
          }

					// Force the over-provisioning to choose a fresh set of objects
					_nextUp = BibopHeap::_overProvObjBufSize;

					_shiftBits = shiftBits;
					_classSize = (size_t)(1U << _shiftBits);

					// Check whether the current bag size can support the current
					// entropy setting (e.g., if any bag has fewer objects than
					// needed to fill its object cache or over-provisioning buffer,
					// then we cannot support the current entropy setting).
					unsigned numObjectsInBag = _bibopBagSize / _classSize;
					bool overProvFail = (numObjectsInBag < BibopHeap::_overProvObjBufSize);
					bool entropyFail = (numObjectsInBag < BibopHeap::_cacheSize);
					if(overProvFail) {
							PRERR("cannot support the given over-provisioning factor:");
							PRERR("           class size = %zu", _classSize);
							PRERR("   num objects in bag = %u", numObjectsInBag);
							PRERR("   over prov buf size = %u", BibopHeap::_overProvObjBufSize);
					}
					if(entropyFail) {
							PRERR("cannot support the given allocator entropy:");
							PRERR("           class size = %zu", _classSize);
							PRERR("   num objects in bag = %u", numObjectsInBag);
							PRERR("       obj cache size = %u", BibopHeap::_cacheSize);
					}
					if(overProvFail || entropyFail) { exit(EXIT_FAILURE); }

					_freeCache = freeCache;
					_numUsedObjects = 0;
					_heapTop = ustartaddr;		// next available object
					_bagEnd = uendaddr;				// last available object
					_objects = (void **)objectCache;
					_nextObjs = objectCache + BibopHeap::_cacheSize;
			}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %rax
movq %rdi, %rbx
pcmpeqd %xmm0, %xmm0
movdqu %xmm0, 0x44(%rdi)
movdqu %xmm0, 0x34(%rdi)
movq 0x6505(%rip), %r14      # 0xcf98
movl (%r14), %edi
movl %edi, 0x28(%rbx)
movl $0x1, %r10d
movl %r9d, %ecx
shll %cl, %r10d
movl %r9d, 0x30(%rbx)
movq %r10, 0x10(%rbx)
movq 0x64f4(%rip), %rcx      # 0xcfa8
movq (%rcx), %rbp
movl %r9d, %ecx
shrq %cl, %rbp
movq 0x64ac(%rip), %r13      # 0xcf70
movl (%r13), %r15d
cmpl %ebp, %edi
ja 0x6b07
cmpl %ebp, %r15d
ja 0x6c79
movq %r8, 0x8(%rbx)
movl $0x0, 0x2c(%rbx)
movq %rsi, 0x20(%rbx)
movq %rdx, 0x18(%rbx)
movq %rax, 0x58(%rbx)
movl (%r13), %ecx
leaq (%rax,%rcx,8), %rax
movq %rax, 0x60(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x41e0
movq %rax, %r12
callq 0x4250
movq %rax, 0x8(%rsp)
leaq 0x2f37(%rip), %rdx      # 0x9a57
leaq 0x2a63(%rip), %r8       # 0x958a
movl $0x1000, %esi           # imm = 0x1000
movq %r12, %rdi
movq %rax, %rcx
movl $0x176, %r9d            # imm = 0x176
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %r12
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %r12, %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movq 0x10(%rbx), %rcx
movq %rcx, (%rsp)
leaq 0x2f36(%rip), %rdx      # 0x9aae
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq 0x8(%rsp), %r12
movq %r12, %rcx
leaq 0x29fb(%rip), %r8       # 0x958a
movl $0x177, %r9d            # imm = 0x177
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, 0x10(%rsp)
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq 0x10(%rsp), %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movl %ebp, (%rsp)
leaq 0x2f1a(%rip), %rdx      # 0x9aee
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq %r12, %rcx
leaq 0x29a4(%rip), %r8       # 0x958a
movl $0x178, %r9d            # imm = 0x178
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %r12
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %r12, %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movl (%r14), %ecx
movl %ecx, (%rsp)
leaq 0x2f03(%rip), %rdx      # 0x9b2d
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq 0x8(%rsp), %rcx
leaq 0x294c(%rip), %r8       # 0x958a
movl $0x179, %r9d            # imm = 0x179
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %r14
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %r14, %rsi
movq %rax, %rdx
callq 0x40f0
cmpl %ebp, %r15d
jbe 0x6dcd
callq 0x41e0
movq %rax, %r12
callq 0x4250
movq %rax, %r14
leaq 0x2edc(%rip), %rdx      # 0x9b6c
leaq 0x28f3(%rip), %r15      # 0x958a
movl $0x1000, %esi           # imm = 0x1000
movq %r12, %rdi
movq %rax, %rcx
movq %r15, %r8
movl $0x17c, %r9d            # imm = 0x17C
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %r12
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %r12, %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movq 0x10(%rbx), %rcx
movq %rcx, (%rsp)
leaq 0x2dc3(%rip), %rdx      # 0x9aae
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq %r14, %rcx
movq %r15, %r8
movl $0x17d, %r9d            # imm = 0x17D
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %rbx
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movl %ebp, (%rsp)
leaq 0x2db4(%rip), %rdx      # 0x9aee
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq %r14, %rcx
movq %r15, %r8
movl $0x17e, %r9d            # imm = 0x17E
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %rbx
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x40f0
callq 0x41e0
movl (%r13), %ecx
movl %ecx, (%rsp)
leaq 0x2e2f(%rip), %rdx      # 0x9bbc
movl $0x1000, %esi           # imm = 0x1000
movq %rax, %rdi
movq %r14, %rcx
movq %r15, %r8
movl $0x17f, %r9d            # imm = 0x17F
xorl %eax, %eax
callq 0x4490
callq 0x41e0
movq %rax, %rbx
callq 0x41e0
movq %rax, %rdi
callq 0x4120
movl $0x2, %edi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x40f0
movl $0x1, %edi
callq 0x4370
nop