// File: /workspace/github_cpp_makefile_star2_O2/ashlall[P]StreamStats/Test/Reservoir_test.cpp
// Function: quicktest()
void quicktest()
{
	ReservoirSampling a(1000);
	for(int i=1; i<=10000000; i++)
	{
		a.insert(i + 0.13416435);
	}

	cout << "0.1: "<<a.getQuantile(0.1) << endl;
	cout << "0.1: "<<a.getQuantile(0.2) << endl;
	cout << "0.3: "<<a.getQuantile(0.3) << endl;
	cout << "0.4: "<<a.getQuantile(0.4) << endl;
	cout << "median:" << a.getQuantile(0.5) << endl;
	cout << "0.6: "<<a.getQuantile(0.6) << endl;
	cout << "0.7: "<<a.getQuantile(0.7) << endl;
	cout << "0.8: "<<a.getQuantile(0.8) << endl;
	cout << "0.9: "<<a.getQuantile(0.9) << endl;
	cout << "1: "<<a.getQuantile(1) << endl;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
leaq 0x3320(%rip), %rax      # 0x4d78
leaq -0x28(%rbp), %rbx
movq %rax, (%rbx)
movl $0x3e8, 0xc(%rbx)       # imm = 0x3E8
movl $0x1f40, %edi           # imm = 0x1F40
callq 0x1030
movq %rax, 0x10(%rbx)
andl $0x0, 0x8(%rbx)
movsd 0x1588(%rip), %xmm0     # 0x3008
movl $0x989680, %r14d        # imm = 0x989680
subl $0x1, %r14d
jb 0x1ab5
movsd %xmm0, -0x30(%rbp)
movsd -0x30(%rbp), %xmm0
addsd 0x158a(%rip), %xmm0     # 0x3028
movq %rbx, %rdi
callq 0x13e0
movsd -0x30(%rbp), %xmm0
addsd 0x1555(%rip), %xmm0     # 0x3008
jmp 0x1a86
movq 0x351c(%rip), %rdi      # 0x4fd8
leaq 0x16bd(%rip), %rsi      # 0x3180
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x1559(%rip), %xmm0     # 0x3030
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x34e5(%rip), %rdi      # 0x4fd8
leaq 0x1686(%rip), %rsi      # 0x3180
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x152a(%rip), %xmm0     # 0x3038
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x34ae(%rip), %rdi      # 0x4fd8
leaq 0x1655(%rip), %rsi      # 0x3186
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x14fb(%rip), %xmm0     # 0x3040
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x3477(%rip), %rdi      # 0x4fd8
leaq 0x1624(%rip), %rsi      # 0x318c
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x14cc(%rip), %xmm0     # 0x3048
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x3440(%rip), %rdi      # 0x4fd8
leaq 0x15f3(%rip), %rsi      # 0x3192
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x149d(%rip), %xmm0     # 0x3050
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x3409(%rip), %rdi      # 0x4fd8
leaq 0x15c4(%rip), %rsi      # 0x319a
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x146e(%rip), %xmm0     # 0x3058
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x33d2(%rip), %rdi      # 0x4fd8
leaq 0x1593(%rip), %rsi      # 0x31a0
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x143f(%rip), %xmm0     # 0x3060
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x339b(%rip), %rdi      # 0x4fd8
leaq 0x1562(%rip), %rsi      # 0x31a6
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x1410(%rip), %xmm0     # 0x3068
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x3364(%rip), %rdi      # 0x4fd8
leaq 0x1531(%rip), %rsi      # 0x31ac
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x13e1(%rip), %xmm0     # 0x3070
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
movq 0x332d(%rip), %rdi      # 0x4fd8
leaq 0x14d0(%rip), %rsi      # 0x3182
callq 0x10d0
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
movsd 0x1342(%rip), %xmm0     # 0x3008
callq 0x143a
movq %rbx, %rdi
callq 0x1100
movq %rax, %rdi
callq 0x1050
leaq -0x28(%rbp), %rdi
callq 0x13c0
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
callq 0x13c0
movq %rbx, %rdi
callq 0x1120